On 12/09/18 16:29, Florian Bergmann wrote:
On the other hand I feel given the documentation, passing the `ip_address` would
be the right thing to do, so I am wondering if I am missing something very
obvious here (especially given that the code seems to be unchanged for 18
years).
Whatever the do
On 12/09/18 15:29, Florian Bergmann wrote:
Hello,
While I was debugging some salt issues I dug into the python code and found a
piece of code in the `socket.py` module that surprised my a bit:
In the `getfqdn` function the `gethostbyaddr` name function is being called with
a `hostname` instead
Hello,
While I was debugging some salt issues I dug into the python code and found a
piece of code in the `socket.py` module that surprised my a bit:
In the `getfqdn` function the `gethostbyaddr` name function is being called with
a `hostname` instead of an `ipaddress`:
```python
def getfqdn
Chris
Thank you for the info. I figure it out. But thank you again.
Ed
> On Jul 28, 2014, at 5:42 PM, Chris Kaynor wrote:
>
> On Mon, Jul 28, 2014 at 2:33 PM, Edward Manning wrote:
> I wrote this code, but it seem to work fine if I only have one ip in the
> file. When I have more than one
On Mon, Jul 28, 2014 at 2:33 PM, Edward Manning
wrote:
> I wrote this code, but it seem to work fine if I only have one ip in the
> file. When I have more than one IP in the file
>
> I get a error. Does anyone have an idea why.
>
It would be helpful to know what the error you are getting is. It
I wrote this code, but it seem to work fine if I only have one ip in the file.
When I have more than one IP in the file
I get a error. Does anyone have an idea why.
import socket
def main():
# get file names
infileName = input ("What file our the IP adderss in? ")
outfile
mport *
>>>> x = gethostbyname('google.com')
>>>> x
>'64.233.167.99'
>>>> gethostbyaddr(x)
>('py-in-f99.google.com', [], ['64.233.167.99'])
>>>> e = '192.168.4.123'
>>>> gethostbyaddr(e)
&
4 (#1, Oct 18 2006, 10:34:39)
> [GCC 4.0.1 (Apple Computer, Inc. build 5341)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> >>> from socket import *
> >>> x = gethostbyname('go
lp", "copyright", "credits" or "license" for more information.
>>> from socket import *
>>> x = gethostbyname('google.com')
>>> x
'64.233.167.99'
>>> gethostbyaddr(x)
('py-in-f99.google.com', [], [