Find the answer to your Linux question:
Results 1 to 3 of 3
Hey, i have a file listing a number of ip addresses and i would like each of these to be run thru the nmblookup command and the output to be ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Dec 2007
    Posts
    2

    Nmblookup help


    Hey, i have a file listing a number of ip addresses and i would like each of these to be run thru the nmblookup command and the output to be directed to another file. I know its possible as i watched my lectureur do it about a month ago but can't recall how to do it myself.

    Thanks,

  2. #2
    Just Joined!
    Join Date
    Dec 2007
    Location
    Great mighty Czech Republic, in the heart of Europe :-)
    Posts
    11
    Your post is not concrete enough, so I cannot answer it in detail. But for the processing of content of file, this simple script should do it.
    (modify it according to your needs and paste to console)

    Code:
    while read IP; do
    nmblookup your parameters $IP >> output_of_nmblookup.txt
    done < your input file

  3. #3
    Just Joined!
    Join Date
    Dec 2007
    Posts
    2
    That done the trick thank you Xman

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •