หน้าเว็บ

แสดงบทความที่มีป้ายกำกับ tool แสดงบทความทั้งหมด
แสดงบทความที่มีป้ายกำกับ tool แสดงบทความทั้งหมด

วันอังคารที่ 3 พฤศจิกายน พ.ศ. 2552

Introduction To VMware VIX API

Introduction to VMware VIX API.


The VIX API allows you to automate virtual machine operations on VMware Server or VMware Workstation.


About the VIX API

The VIX API (or "Vix") is a library for writing scripts and programs to manipulate virtual machines. It is high-level, easy to use, and practical for both script developers and application programmers. The VIX API is designed for three kinds of users:

  • Technically Adventurous Users - For example, dedicated IT personnel in an organization building their own in-house tools.
  • Partners - Software vendors using Vix to integrate VMware products with their own products or to build management products specifically for virtual machines.
  • VMware Engineering - VMware uses Vix in its own products as a general abstraction layer between core virtual machine processes and associated service processes.

The VIX API runs on Microsoft Windows (Windows95 or later) and Linux platforms (kernel 2.4.x or later recommended). It supports programs written in C, Perl, and COM (Visual Basic, VBscript, C#).


Compatibility

This release of the VIX API is compatible with VMware Server 2.0 and VMware Workstation 6.5.

Product Compatibility

VIX API Version

Compatible Platform Products

Library Location

1.0.3

VMware Server 1.0

server-1

1.1

VMware Workstation 6.0

ws-3

1.1.1

VMware Workstation 6.0.1 or earlier

ws-3

1.1.2

VMware Workstation 6.0.2 or earlier

ws-3

1.1.4

VMware Workstation 6.0.4 or earlier

ws-5

1.1.5

VMware Workstation 6.0.5 or earlier

ws-5

1.6.0

VMware Server 2.0 or earlier

VIServer-2.0.0

1.6.1

Workstation 6.5 or earlier

Workstation-6.5.0

The library location is not important if you use the wrapper library as recommended.

Vix Version 1.x supports programs written to version 1.x of the VIX API. Exceptions are noted on function reference pages. For example, VMware Server does not support record and replay, while VMware Workstation does not support virtual machine registration.

Vix libraries are installed with VMware Server and VMware Workstation and provide API compatibility corresponding to the product release. Vix libraries are downward compatible in most cases. If you upgrade VMware Server or VMware Workstation, you should also upgrade any separately installed Vix libraries. For instructions, see Installing the VIX API. You should also upgrade VMware Tools to match the product release.

With VMware Server, you can run Vix programs remotely. With VMware Workstation, Vix programs usually run on the host.


64-Bit Library Support

The VIX API provides 64-bit libraries for Linux only. Windows 32-bit libraries may work in 64-bit emulation mode.


Redistributable Code and Sample Code

As noted in the End User License Agreement, the VIX API allows you to build and distribute your own applications. To facilitate this, the following files are designated as redistributable for the purpose of that agreement:

  • VixAllProducts.lib and VixAllProductsd.lib
  • vix.lib and vix.dll
  • vixCOM.dll
  • libvixAllProducts.so
  • libvix.so

Redistribution of the open source libraries included with the VIX API is governed by their respective open source license agreements.

The VIX API also includes sample code, which you can use as a starting point for your own programs. Code is delivered in the Samples directory installed with VMware VIX. A Makefile is provided for Linux, and an nMakefile for Windows.


Installing the VIX API

On the VMware Server or VMware Workstation host, you do not need to install any additional VIX API components. Vix libraries are installed by default under “VMware VIX” or vmware-vix. To compile programs on these systems


To control VMware Server remotely from another machine, you need header files vix.h and vm_basic_types.h, as well as one or more library files. You can get these files in one of two ways: Use the Vix standalone installer to get the files needed to compile a program


Using the Windows Standalone Installer

To install the VIX API files on Windows:

  1. Download the installer program to your Desktop.
  2. Double-click the installer icon to run the graphical installer.

To uninstall the VIX API, go to Start > Settings > Control Panel and use the Add/Remove Programs control panel.


Using the Linux Standalone Installer

To install the VIX API files on Linux:

  1. Download the tar-gzip package. For example:
    wget http://www.vmware.com/downloads/server/VMware-vix-110068.i386.tar.gz
  2. As superuser, extract the package:
    sudo tar zxpf VMware-vix-110068.i386.tar.gz
  3. Change directory and, as superuser, run the VMware installer:
    cd vmware-vix-distrib
    sudo ./vmware-install.pl
  4. Read the EULA and type "yes" if you agree to its terms. You can accept most defaults by typing Enter when prompted.

To uninstall the VIX API, run the vmware-uninstall-vix.pl script. The uninstaller is at /usr/bin/vmware-uninstall-vix.pl by default.


Upgrading an Earlier Installation

If you are using older Vix libraries, VMware recommends that you upgrade those libraries using the standalone installer. The standalone installer provides a current version of the wrapper library, which allows programs to communicate with any Vix library, regardless of version or target architecture. The wrapper library dynamically loads appropriate library files at connection time.

Otherwise you must link your program to a Vix library that matches the server version. This gets inconvenient if your program communicates with more than one version of the server.

VMware Tools in virtual machines should be kept up-to-date with the VMware version on the host. When upgrading, also update VMware Tools in all guest operating systems. The VIX API relies on a current matching version of VMware Tools to perform many operations.

Upgrading the Vix libraries replaces the older header files, vix.h and vm_basic_types.h with newer header files. The header files are installed at the following locations by default:

  • On a Windows system:
    • C:\Program Files\VMware\VMware VIX\vix.h
    • C:\Program Files\VMware\VMware VIX\vm_basic_types.h
  • On a Linux system:
    • /usr/include/vmware-vix/vix.h
    • /usr/include/vmware-vix/vm_basic_types.h

Whether or not you use the wrapper library, your programs may call only the functions supported by the host. If you communicate with an older host, you cannot use newer features.


Sample Vix Programs

On Windows, the sample programs are installed in C:\Program Files\VMware\VMware VIX\Samples by default. An nMakefile is provided to compile all sample programs using nmake and the Visual Studio C compiler.

On Linux, the sample programs are installed in /usr/share/doc/vmware-vix/VMwareVix/samples/ by default. A Makefile is provided to compile all sample programs using make and the GNU C compiler.

Compiling on Windows With Wrapper Library

To use the wrapper library with VIX 1.6, you need Visual Studio 2005 (Visual C release 8.0) or later. To compile code on Windows using the wrapper library, use the following procedure. Files are in the C:\Program Files\VMware\VMware VIX folder.

  1. Add the header file to an include statement in your source code:
  2. #include "vix.h"
    ... program code here ...
  3. Compile for, and link with, the multithreaded version of the C runtime library. For Workstation 6.0.1 and later, you may use either the debug or the non-debug version of this library. For Workstation 6.0.0 and earlier, you must use the non-debug version.
    • To compile and link with the debug version (libcmtd.lib) use compiler options /MTd /nodefaultlib:libcmtd.lib.
    • To compile and link with the non-debug version (libcmt.lib) use compiler options /MT /nodefaultlib:libcmt.lib.
  4. Compile code to link with these files:
    • VixAllProducts.lib for non-debug, or VixAllProductsd.lib for debug.
    • kernel32.lib
    • user32.lib
    • advapi32.lib
    • ole32.lib
    • oleaut32.lib
    • ws2_32.lib
    • shell32.lib

Compiling on Linux With Wrapper Library

This procedure assumes that you have installed Vix components in the default directories. If you made different choices during the installation, specify your directory choices instead.

  1. Add an include statement in your source code for the header file:
    #include "vix.h"
    ... program code here ...
  2. Compile your application, linking to the wrapper library and dynamic load library:
    $ gcc -I/usr/include/vmware-vix vixapp.c -o vixapp -lvixAllProducts -ldl

Compiling on Windows Without Wrapper Library

If you do not use the wrapper, you need to link the appropriate Vix libraries for the VMware product to which your Vix program connects. Workstation 6.5 is able to link a debug version of the C runtime library.

To compile your code for use with Workstation 6.5:

  1. Make the required DLL files available to your program, either by placing them in the same directory as your executable, or by placing them in the system directory (C:\WINDOWS\system32). The easiest option is to copy DLL files from the directory C:\Program Files\VMware\VMware VIX\Workstation-6.5.0\32bit or 64bit.
    • vix.dll (or vixd.dll if you are using debug C runtime library)
    • iconv.dll (or inconvd.dll if you are using debug C runtime library)
    • libxml2.dll (or libxml2d.dll if you are using debug C runtime library)
    • libeay32.dll
    • ssleay32.dll
    • vmcryptolib.dll
    • zlib1.dll
  2. Add the header file to an include statement in your source code:
    #include "vix.h"
    ... program code here ...
  3. Compile your code to link in vix.lib statically.
  4. Compile for, and link with, the multithreaded version of the C runtime library. You may use either the debug or the non-debug version of this library.
    • To compile and link with the debug version (libcmtd.lib) use compiler option /MTd with Microsoft Visual Studio.
    • To compile and link with the non-debug version (libcmt.lib) use compiler option /MT with Microsoft Visual Studio.

To compile your code for use with Workstation 6.0.x:

  1. Make the required DLL files available to your program, either by placing them in the same directory as your executable, or by placing them in the system directory (C:\WINDOWS\system32). The easiest option is to copy DLL files from the directory C:\Program Files\VMware\VMware VIX\ws-2\32bit or ws-3\32bit.
    • vix.dll
    • iconv.dll
    • libxml2.dll
    • libeay32.dll
    • ssleay32.dll
    • vmcryptolib.dll
    • zlib1.dll
  2. Add the header file to an include statement in your source code:
    #include "vix.h"
    ... program code here ...
  3. Compile your code to link in vix.lib statically.
  4. Compile for, and link with, the multithreaded version of the C runtime library. You must use the non-debug version of this library (libcmt.lib) by using compiler option /MT with Microsoft Visual Studio.

To compile your code for use with VMware Server 1.0:

  1. Make the following DLL files available to your program, either by placing them in the same directory as your executable, or by placing them in your system directory (C:\WINDOWS\system32). The easiest option is to copy DLL files from the directory C:\Program Files\VMware\VMware VIX\server-1\32bit.
    • vix.dll
    • ssleay32.dll
    • libeay32.dll
  2. Add the header file to an include statement in your source code:
    #include "vix.h"
    ... program code here ...
  3. Compile your code to link in vix.lib statically.

Compiling on Linux Without Wrapper Library

To compile your code with VMware Server or VMware Workstation installed:

  1. Add an include statement in your source code for the header file:
    #include "vix.h"
    ... program code here ...
  2. Compile your application, linking statically to libvix.so, as in the following examples.
    • To link the VMware Workstation library on a 32-bit machine:
      gcc -I/usr/include/vmware-vix -o vixapp vixapp.c /usr/lib/vmware-vix/Workstation-6.5.0/32bit/libvix.so
    • To link the VMware Server 2.0 library on a 32-bit machine:
      gcc -I/usr/include/vmware-vix -o vixapp vixapp.c /usr/lib/vmware-vix/lib/VIServer-2.0.0/32bit/libvix.so
    • To link the old VMware Server 1.x library:
      gcc -I/usr/include/vmware-vix -o vixapp vixapp.c /usr/lib/vmware-vix/lib/server-1/32bit/libvix.so
Thanks : VMware.com

วันพุธที่ 21 ตุลาคม พ.ศ. 2552

Guard of Thumb Drive

หากคุณใช้ Thumb Drive คุณต้องมีโปรแกรมนี้
Remora USB Disk Guard
สวัสดีคร๊าบบบบ เมื่อบทความที่แล้วแนะนำกันเรื่องโปรแกรมยอดฮิตสำหรั บใช้งานกับ Thumb Drive หรือ USB Drive ไปเรียบร้อยแล้ว ซึ่งในช่วงงาน ComMart ที่ผ่านมาหลายคนกวาดซื้อ Thumb Drive กันไปเพียบเพราะลดราคาถูกมาก งั้นขอเม๊าส์ก่อนดีกว่า วันสุดท้ายที่ผมลากเว็บมาสเตอร์ไปเก็บตกสินค้าราคาถู กในงานวันสุดท้ายผมเองก็คว้า Thumb Drive ขนาด 2 GB มาเหมือนกัน ในราคาไม่ถึง 500 บาท เมื่อวานนี้แวะไปพันธ์ทิพย์ เจอเหมือนกับที่ผมซื้อเลยขนาด 512 MB ก็ปาเข้าไปตั้ง 450 บาทแล้ว โฮ โฮ โฮ ( หัวเราะแบบซานตาครอส ) ผมได้ราคามาแบบมิตรภาพจริงๆ แต่ก็นั่นหละขนาดความจุตั้ง 2 GB ผมยัดทั้งงานและข้อมูลสำคัญๆที่ต้องเอาไปใช้ไปมาระหว ่างบ้านกับ Office จริงๆใส่ใน Card ของเครื่อง PDA Phone ก็ได้แต่ว่ามันขี้เกียจต้องมานั่งจั๊มสาย เลยใช้แบบ Thumb Drive นี่หละสะดวกดีใช่ไม๊ครับ
แต่ทว่าเกิดวันหนึ่ง เจ้า Thumb Drive สุดที่รักที่มีขนาดเล็กจิ๋วลงทุกๆวัน เกิดมันหายไปหละครับ ? ก็แน่นอนหละเสียดายมันคงต้องเสียดาย แม้มูลค่ามันจะไม่กี่ร้อยก็ตาม แต่ว่าข้อมูลในนั่นหนะสิครับ บางครั้งมันไม่สามารถประเมินมูลค่าได้ หากข้อมูลสำคัญที่เก็บไว้ในนั้นเกิดไปตกอยู่ในมือผู้ ที่อาจจะไม่ประสงค์ดี เผลอๆเดี๋ยยวมีภาพหลุดไปท่องตามเน็ตหละยุ่งเลย
มันก็เลยเป็นที่มาของบทความในวันนี้กับโปรแกรมที่ผมอ ยากจะบอกว่า " คุณควรต้องมีใน Thumb Drive " โปรแกรมตัวนี้ชื่อว่า Remora USB Disk Guard เป็นโปรแกรมแบบฟรีแวร์ใช้ได้เลย ไม่ต้องจ่ายสตางค์ซื้อ เป็นโปรแกรมที่จะช่วยในการเข้ารหัสข้อมูลไฟล์ที่เก็บ ใน Thumb Drive หากสักวันหนึ่งมันโดนจิ๊กไป หรือทำหล่นหาย ก็แน่ใจเลยว่าข้อมูลใน Thumb Drive ในขนาดเป็น GB รับรองว่าไม่ถูกมือดีสามารถนำไปใช้ได้แน่

มาดูวิธีใช้กันดีกว่า ไม่ยากครับแต่อาจจะมีขั้นตอนยุ่งยากนิดหน่อย
1. ไป Download โปรแกรมนี้ได้ฟรีที่ http://download.richskills.com/remor...uard_green.exe
Click the image to open in full size.
2. ทำการติดตั้งเหมือนโปรแกรมทั่วไป
Click the image to open in full size.
3. เลือก Drive ที่จะติดตั้งให้เลือกที่ Drive ที่เป็น Thumb Drive นะครับอย่างของผมคือ Drive F:/
Click the image to open in full size.
4.เลือกภาษาเป็น English
Click the image to open in full size.
5. Step ที่ 1 ตั้งรหัสผ่านอย่างน้อยหกตัว ทั้งสองช่อง
Click the image to open in full size.
6. Step ที่ 2 ตั้งรหัสผ่านอย่างน้อยหกตัวอีกรอบ สำหรับการเข้ารหัส File แนะนำว่าให้ใช้รหัสเดียวกับใน Step ที่ 1 จะได้จำง่ายไม่มีลืม
Click the image to open in full size.
7. เมื่อติดตั้งเสร็จจะปรากฎ icon บน task bar ของ Windows สีแดงๆในรูป
8.ไปที่ My Computer แล้วเข้าไปใน Thumb Drive สร้าง Folder เตรียมไว้เก็บข้อมูลก่อนหนึ่ง Folder ในกรณีของผมผมสร้างแล้วตั้งชื่อว่า "โฟลเดอร์ข้อมูลลับ"
Click the image to open in full size.
9.การเรียกโปรแกรมให้ Double Click ที่ icon บน Task bar แล้วจะปรากฎหน้าต่างให้ Log on
Click the image to open in full size.

10. เมื่อโปรแกรมเรียกขึ้นมาแล้วจะมีหน้าตาแบบในรูปนี้หล ะครับ ส่วนคำอธิบายก็ตามภาพเลย
Click the image to open in full size.

11. ให้ทำการเอาไฟล์ข้อมูลที่จะเก็บลง Thumb Drive ไปใส่ไว้ใน Folder "โฟลเดอร์ข้อมูลลับ" ที่สร้างเตรียมไว้ล่วงหน้า ในตัวอย่างนี้ผมเอาไฟล์ excel ไปใส่ไว้
Click the image to open in full size.

12.หลังจากนั้น ก็เลือกที่ การเข้ารหัสแบบ Folder ที่ตัวโปรแกรม Remora USB Disk Guard แล้วก็เลือกที่ Folder "โฟลเดอร์ข้อมูลลับ" เพื่อทำการเข้ารหัสไฟล์ที่เก็บใน Folder นั้นทั้งหมด
Click the image to open in full size.
13. เรียบร้อยแล้วครับ !! พอเวลาเรามาเปิดดู Folder ที่ชื่อว่า "โฟลเดอร์ข้อมูลลับ" ที่เราเข้ารหัสไว้ ไฟล์ที่เก็บในนั้นจะเป็นไฟล์คล้ายๆพวกไฟล์ขยะ ไม่สามารถเปิดออกได้ แต่หากต้องการเรียกใช้ไฟล์เหล่านั้น ก็ต้องไปปลดล๊อคก่อนนะครับ
ขอแถมก่อนจบสักหน่อย !!

ในเครื่องพวก PDA Phone เองเราก็สามารถทำให้ Card ที่อยู่ในเครื่องสามารถเป็น Thumb Drive ได้เช่นเดียวกันโดยใช้โปรแกรมที่ชื่อว่า WM5torage สามารถ Download ได้จากที่ http://www.modaco.com/WM5torage-t238545.html
และหากต้องการแบ่ง พาเทชั่น ของ SD Card / Mini SD หรือ Micro SD แนะนำให้ลองอ่านที่บทความนี้ครับ http://www.mrpalm.com/list33.php?cont_id=284


Thanks : thaigaming.com

วันอังคารที่ 29 กันยายน พ.ศ. 2552

Powerline Networking

Thanks : unlimitpc.com


สวัสดีครับพี่น้องทั้งหลายแห่ง UPC แห่งนี้ วันนี้ผมขอนำเสนอของที่ใครหลายๆอาจจะไม่ค่อยรู้จักดีนักในส่วนของ HomePlug หรือที่เรียกกันอย่างเป็นทางการว่า Powerline Networking เอาเป็นภาษาไทยก็คือ เป็นอุปกรณ์เครือข่ายที่ใช้งานผ่านสายไฟฟ้า ซึ่งเป็นอุปกรณ์ที่ส่งข้อมูลระหว่าง PC โดยผ่านสายไฟฟ้าภายในตัวอาคารแทนที่การเดินสายแลน นั่นเองครับ โดยวันนี้ผมมีของจาก Aztech Homeplug Powerline Networking มาให้ชม หากใครยังไม่ค่อยทราบว่าจะใช้งานอย่างไร เป็นแบบไหน เลื่อเม้าส์ลงมาดูครับ

พอจะนึกออกแล้วบอกว่าอ๋อกันแน่ๆ เจ้า Homeplug มีหลักการทำงานอย่างง่ายๆ โดยเสียบสายแลนต่อกับ PC ของพี่น้องและเสียบไปยัง Home plug และนำเจ้าตัวนี้เสียบลงปลั๊กไฟธรรมดา โดยอีกฝากหนึ่งจะต้องมีเจ้าตัว Homeplug เพื่อเสียบต่อกับ PC อีกตัวหรืออุปกรณ์เน็ตเวิร์คจึงจะสามารถใช้งาน network ผ่านสายไฟฟ้าได้ครับ ทั้งนี้ระยะการทำงานของเจ้า Homeplug นั้นจะไม่เกิน 200 เมตร โดยการโอนถ่ายข้อมูลที่เคยทำได้สูงสุดนั้นสามารถโอนถ่ายได้ถึง 200 Mbps และยังสามารถต่อได้มากกว่า 2 จุดครับ

อีกแบบนึงที่จะสามารถใช้งานในรูปแบบ entertainment โดยสามารถต่อเข้ากับ IPTV หรือ Media Sharing พร้อมรับชมภาพยนตร์แบบ HD ได้สบายๆ ไม่รกสาย

และนี่คืออุปกรณตัวจริงที่ผมขอนำเสนอพี่น้องในวันนี้ครับ นั่นคือ Aztech Powerline Networking HL-105E Twin Pack ครับ กล่องสีขาว-แดง เหมือนจะตามแบบของ Dcom ซะด้วย

รับประกันคุณภาพ 2 ปีเต็มจาก Dcom ครับ

สำหรับ Aztech HL-105E เป็นชิพผู้ผลิตต้นแบบจาก Intellon โดยอยู่ในสังกัดของ Homeplug Powerline Alliance นั่นเองครับ รุ่นนี้เป็นตัว Turbo ที่สามารถให้ความเร็วสูงถึง 85 Mbps

ด้านหลังจะบอกรายละเอียดรวมถึงวิธีการติดตั้ง ซึ่งสามารถดัดแปลงได้หลายรูปแบบครับ

ภายในกล่องจะมีเจ้า Homeplug HL-105E ให้จำนวน 1 คู่พร้อมสายแลนด้วยกัน 2 เส้น

สำหรับขาเสียบนั้นออกแบบเป็นขากลมครับ หน้าตาและรูปร่างเหมือน Adaptor ธรรมดาทั่วไป ขนาดไม่ใหญ่มาก โดยจะมีรูระบายความร้อนอยู่หลายจุด

จากตัวด้านหน้าจะสกรีนยี่ห้อ และรายละเอียดต่างๆ มีไฟแสดงสถานะจำนวน 3 ชุด คือไฟแสดงสถานะไฟเข้า, PL-ACT จะติดเมื่อพบตัว homeplug อีกจุดหนึ่งและจะกระพิบเมื่อมีการรับ-ส่งข้อมูล และสุดท้ายจะเป็นไฟแสดงสถานะเมื่อมีการส่งถ่ายข้อมูลผ่านเครือข่ายหรืออุ ปกรณ์เน็ตเวิร์คต่างๆครับ

ด้านล่างเป็นช่อง Ethernet ไว้สำหรับเสียบสาย LAN คร้าบ

ว่าแล้วก็ลองเสียบเลยครับ เมื่อใช้งานก็ไม่ยากครับ อย่างที่เห็นครับ เสียบ และ เสียบ!!!

หลายท่านคงอาจจะไม่เห็นภาพ เนื่องจากไม่ได้ถ่ายภาพมา 2 จุด ผมเลยขอยกตัวอย่างตามนี้ครับ โดยจุดนึงนั้นเสียบเจ้า homeplug กับ ADSL Router และอีกด้านกับ PC หรือ โน๊ตบุ๊คซึ่งจะอยู่กันคนละห้อง หรือคนละชั้นได้อย่างสบายๆ (ภาพจาก www.aztech.com)

เมื่อเสียบสายและต่อเข้ากับ Notebook ซึ่งเมื่อเสียบแล้วก็พร้อมใช้งานได้ทันทีครับ

PowerPacket Utility:

เป็นโปรแกรมที่แถมมาให้ในกล่องพร้อมเจ้า HomePlug ชุดนี้เพื่อเพิ่มประสิทธิภาพและการตั้งค่าต่างๆได้อย่างสะดวกครับ

หน้าแรกด้านบนจะแสดง MAC Adress ของตัว HomePlug ส่วนด้านล่างจะเป็นตัวแสดงสถานะหากมีอุปกรณ์ Homeplug ตัวอื่นๆใน Network เดียวกันรวมถึง คุณภาพสัญญาณ และอัตราการรับส่งข้อมูล และมีรหัสผ่านด้วยครับ

หน้าต่อมาจะเป็นการตั้งชื่อ Network ครับ หากตั้งไม่ตรงกันจะไม่สามารถตรวจพบหรือใช้งานได้นะครับ

นอกจากนี้เจ้า HomePlug ยังมีฟังก์ชั่น QOS หรือ Quality of Service สามารถจัดสรรตามความต้องการใช้งานในแต่ละรูปแบบได้ด้วย

ส่วนของ Diagnostic ครับสามารถตรวจสอบการทำงานได้

Conclusion:

Aztech Powerline Networking HomePlug Turbo นี้ยังยังถือเป็นสิ่งที่ตอบโจทย์ให้กับหลายๆท่านได้อยู่ สำหรับผู้ที่ไม่ต้องการใช้ Wireless เพราะกลัวโดน hack หรือผู้ที่ต้องการใช้งาน Network โดยไม่ต้องวุ่นวายเดินสาย LAN ใหม่เป็นระยะทางไกล ไม่รกสาย เพียงแค่เสียบปลั๊กและต่อสาย LAN เข้ากับ PC หรืออุปกรณ์ต่างๆก้สามารถใช้งานได้แล้ว การตั้งค่านั้นก็ไม่ได้ยุ่งยากมากมาย ในเรื่องของการโอนถ่ายข้อมูลนั้นยังไม่สามารถทำได้สูงสุดถึง 85 Mbps อย่างที่จัดไว้ในสเปค แต่ก็อยู่ในระดับที่น่าพอใจ นอกจากจะใช้งานแบบเครือข่ายอย่างที่ให้ดูคร่าวๆแล้ว ยังสามารถประยุกต์ใช้กับระบบความปลอดภัยอย่างกล้องวงจรปิดได้ หรืออุปกรณ์อื่นๆตามต้องการขอแค่มีปล๊กไฟและสายไฟเท่านั้นก็พอแล้ว สำหรับผู้ที่ต้องการใช้ Homeplug นั้นจะต้องซื้อมาอย่างน้อย 2 ตัวเพื่อรับ-ส่งข้อมูล และสามารถซื้อมาต่อเพิ่มได้มากกว่า 2 ตัวอยู่แล้ว ส่วนค่าตัวนั้นยังอยู่ในระดับสองพันกลางๆถึงปลายๆ ต่อ 1 ชุด ความคุ้มค่านั้นอาจจะต้องดูกันในส่วนของการติดตั้งและใช้งานในแต่ละจุด ประสงค์ของผู้ใช้ครับ สำหรับวันนี้ขอลาไปก่อน สวัสดี ...

NSLOOKUP for DNS Server diagnosis

NSLOOKUP has a fairly rich syntax and can be a bit confusing for those who have not worked with DNS a great deal. Therefore, I want to start out by showing you some of the basics. Although NSLOOKUP exists in both UNIX and Windows, there are some differences in the way that it behaves in the two operating systems. For the purposes of this article, I will be using the Windows version.

The first thing that you need to understand about NSLOOKUP is that when you use the NSLOOKUP command, it assumes that you are querying a local domain on your private network. You can query an external domain, but NSLOOKUP will try to search for the domain internally first. For example, the brienposey.com domain is external to my network. If I perform an NSLOOKUP against brienposey.com, NSLOOKUP returns the information that’s shown in Figure A.


Figure A: This is what happens when NSLOOKUP queries an external domain

If you look at the figure, you will see that there are non existent domain error messages for the IP addresses 147.100.100.34 and 147.100.100.5. These are the addresses of my internal DNS servers. Below this information however is the non authoritative answer. This means that my DNS server queried an external DNS server in an effort to resolve the IP address associated with the brienposey.com domain.

Now, let’s take a look at what happens when you query an internal domain. One of the local domains on my private network is production.com. If I perform an NSLOOKUP against production.com, I get the results shown in Figure B.


Figure B: This is what it looks like when I query an internal domain

If you look at the top portion of this screen, you will notice that I’m getting the exact same non-existent domain error messages as I got when I queried an external domain. At first, this may seem puzzling. The reason why I got this error message was because I performed an NSLOOKUP outside of the NSLOOKUP shell. I will talk more about the NSLOOKUP shell in the next section. For now though, you need to know that you can enter the NSLOOKUP command by itself. When you do, you will see the familiar non-existent domain error messages, but you will then be taken to the NSLOOKUP prompt (the > sign). From there you can enter various NSLOOKUP commands. When you are done, you can use the EXIT command to return to the command prompt.

The other thing that you should notice about Figure B is the bottom portion of the output. Beneath the reference to production.com is a string of IP addresses. These are the IP addresses of all of the domain controllers within the domain. I should also point out that if multiple IP addresses are assigned to a single server then all of the server’s IP addresses will be displayed by NSLOOKUP.

The NSLOOKUP Shell

Now that I have shown you how to use the NSLOOKUP command to see the IP address or addresses associated with the domain, let’s do something a little bit more useful. One of the things that you can do with NSLOOKUP is to look up a specific type of DNS record. A good example of this is an MX record.

In case you aren’t yet familiar with all of the intricacies of DNS, the MX record points to the organization’s mail server. For example, suppose that someone wanted to send an E-mail message to you, one of the first things that their mail server would have to do is to resolve your domain’s IP address. However, a normal address resolution won’t usually work for this purpose. In Figure A, you saw that when I ran a DNS query against the brienposey.com domain, the domain resolved to the address 24.235.10.4. Keep in mind though, that this is the IP address of the server that hosts my Web site, not the address of my mail server. If someone wanted to send me an E-mail message their E-mail client would have to resolve the IP address of my domain’s mail server. This is where the MX record comes into play. The MX record is a record on a domain’s DNS server that specifies the IP address of the domain’s mail server.

As you can see, the MX record is rather important. Suppose however that your domain was having trouble receiving E-mail and you suspected that a DNS server issue was to blame. You could use NSLOOKUP to confirm that the domain does indeed have an MX record and that the MX record is pointed to the correct IP address.

Earlier I briefly mentioned that you could work within the NSLOOKUP shell. To troubleshoot an MX record problem, you pretty much have to work within this shell. Therefore, you would start the process by entering the NSLOOKUP command at the command prompt.

Once the NSLOOKUP shell is open, you will need to tell NSLOOKUP which DNS server you want to query. To do so, enter the SERVER command, followed by the DNS server’s IP address. You can also enter the server’s fully qualified domain name (assuming that it can be resolved) as an alternative to the server’s IP address.

Now that you have specified a DNS server for NSLOOKUP to use, you can query domains without receiving the non-existent domain error messages that you saw earlier (as long as you remain within the NSLOOKUP shell). To do so, you would simply type the domain name that you want to query. For example, if you look at Figure C, you can see where I have specified a particular DNS server and then queried an external and an internal domain.


Figure C: The error messages go away if you specify a DNS server

Now, let’s get back to the business of looking up a domain’s MX record. To do so, you need to issue a command that tells NSLOOKUP to query based on MX records. The command that you will have to use is:

SET QUERY=MX

Issuing this command by itself won’t give you any information about the domain’s MX record though. For that you have to actually query the domain by entering the domain name. If you look at Figure D, you will see that I have specified an MX query and then entered the production.com domain name. NSLOOKUP now returns a wealth of information pertaining to my domain’s MX record.


Figure D: When an MX query is specified, you can get a wealth of information about your domain’s MX record

Conclusion

As you can see, NSLOOKUP can provide you with a wealth of DNS server diagnostic information. However, NSLOOKUP is not limited to providing the types of information that I have discussed. The NSLOOKUP shell is actually a fairly rich interface with a rather large command set. You can view a list of the available commands and their syntax by entering a question mark at the NSLOOKUP prompt (note: you can not use NSLOOKUP /? to view the command set).


Thanks : windowsnetworking.com

Linux networking tools

In this Daily Drill Down, I’ll introduce you to five network tools: ping, netstat, whois, nslookup, andfinger. Each of these tools has its own place in a LAN environment, though admittedly ping, netstat, whois, and nslookup are the most useful. These tools can be used to debug network connections in various ways.

ping
You can think of ping as network sonar. It sends out packets of information toward a server. If the remote server is online, ping reports back the number of bytes and time it took to get there. If the server is not online, it will give you an error message that the pinged server does not exist. Use this tool when you need a quick response to see that your network or your ISP's network is online; otherwise you’ll need to use other diagnostic tools.

The command-line structure of ping is
ping[-dfnqrvR] [-c count][-i wait interval ][-l preload] [-p pattern]
[-s packetsize] [-w waitsecs]


A typical readout of ping is shown here:
>ping localhost
> PING localhost.localdomain (127.0.0.1) from 127.0.0.1 :
56(84) bytes of data.
64 bytes from 127.0.0.1: icmp_seq=0 ttl=255 time=0.3 ms
64 bytes from 127.0.0.1: icmp_seq=1 ttl=255 time=0.3 ms
64 bytes from 127.0.0.1: icmp_seq=2 ttl=255 time=0.1 ms
64 bytes from 127.0.0.1: icmp_seq=3 ttl=255 time=0.2 ms


Here we see that localhost.localdomain is connected. While ping will go on forever unless you hit [Ctrl]c, there’s another way to break out of an endless loop. You use the -c option, like so:
>ping -c 10 localhost
PING localhost.localdomain (127.0.0.1) from 127.0.0.1 :
56(84) bytes of data.
64 bytes from 127.0.0.1: icmp_seq=0 ttl=255 time=0.2 ms
64 bytes from 127.0.0.1: icmp_seq=1 ttl=255 time=0.1 ms
64 bytes from 127.0.0.1: icmp_seq=2 ttl=255 time=0.1 ms
64 bytes from 127.0.0.1: icmp_seq=3 ttl=255 time=0.1 ms
64 bytes from 127.0.0.1: icmp_seq=4 ttl=255 time=0.2 ms
64 bytes from 127.0.0.1: icmp_seq=5 ttl=255 time=0.1 ms
64 bytes from 127.0.0.1: icmp_seq=6 ttl=255 time=0.1 ms
64 bytes from 127.0.0.1: icmp_seq=7 ttl=255 time=0.2 ms
64 bytes from 127.0.0.1: icmp_seq=8 ttl=255 time=0.2 ms
64 bytes from 127.0.0.1: icmp_seq=9 ttl=255 time=0.1 ms
--- localhost.localdomain ping statistics ---
10 packets transmitted, 10 packets received, 0% packet loss
round-trip min/avg/max = 0.1/0.1/0.2 ms


If the time seems to remain constant while you’re connected to your ISP, this might mean that the network is jammed.

Why use ping?
If you were an administrator, why would you want to use ping? The answer is that it’s the first line of defense. If you’re not using NT, then ping will tell you quickly if you’re online by sending you packets. It gets your boss off your back when he’s having network problems and barking the question, “Is the network up?” By using ping, you can at least tell him “Yes” or “No.”

Many companies have a mail server with many individual computers connected to it via a proxy server on the network. The direct way to this mail server is to ping it, as shown here:
ping -d -c 25

This command will ping for 25 packets. I think this is a fair amount of packets to test to see whether or not you’re online.
The -d option is for debugging.
If you’re on a workstation and have a proxy IP, then you might try this:
ping -d -r -c 25

This command is nearly the same as the previous example except it will bypass the routing tables. If your e-mail server is online, ping will return packets; otherwise you’ll get an error. This method should work if you’re not an administrator.

Scenario
Your boss yells that he can't send e-mail. What do you do? Using ping can help you with the first steps. If the packets are constant, then there might be a lot of traffic. Tell him to wait and try to send again. If the packets aren't constant, further diagnosis is needed.

netstat
Another major network tool is netstat. The netstat tool can provide you with plenty of information about your network, including information about TCP and UNIX connections. It can also tell you about the status of all the interfaces on your server. Interfaces for Ethernet are identified as eth0, eth1, etc; PPP as ppp0, ppp1, etc; and slip as sl0, sl1, etc. So, if you have one Ethernet connection up and running in the Iface column, it will be shown as UP.

You use the netstat tool to check which of your connections are up. This tool is very useful in a large network setting where you have perhaps 30 or more machines connected to a server and don't have the time to check all of them. You could use netstat to find the bad connections and then use some other network software to reconnect the machine if it finds a software problem, or you could go to the machine yourself and fix the hardware and the software. One place where this would come in handy is on an archive server. If everyone complains that they can't back up their work, you could invoke netstat to see if the server is up and then fix the problem by whatever means possible.

Displaying interface statistics
Invoke netstat at the prompt as follows:
>netstat –I
Kernel Interface table
Iface MTU Met RX-OK RX-ERR RX-DRP RX-OVR TX-OK TX-ERR TX-DRP TX-OVR Flg LRU
lo 3924 0 220 0 0 0 220 0 0 0
ppp0 1500 0 6 0 0 0 6 0 0 0


Let’s look at this command in detail:
  • The MTU and Met fields show the current metric values for the interface (Iface).
  • RX-OK/ERR represents received packets that are okay and those that have errors.
  • TX-OK/EER represents transferred packets that are okay and those that have errors.
  • RX-DRP represents received packets that have been dropped.
  • TX-DRP represents transferred packets that have been dropped.
  • The Flg column shows the flags that have been set for each interface. These values come ifconfig. The ones shown are one-character versions of long flag names:
    L means that this interface is a loopback device.
    R means that this interface is running.
    U means that this interface is up.
    P means that this is a point-to-point interface.
    O means that ARP is turned off for this interface.

Displaying connections
The netstat tool has options to display active and passive sockets. These options show TCP, UDP, RAW, and UNIX socket connections. The flags to show these options are -t, -u, -w, and -x. For example, invoking netstat -ta produces this output:
>netstat –ta
tcp 0 0 *:1052 *:* LISTEN
tcp 0 0 *:1051 *:* LISTEN
tcp 0 0 *:1050 *:* LISTEN
tcp 0 0 *:1049 *:* LISTEN
tcp 0 0 *:1048 *:* LISTEN
tcp 0 0 *:1047 *:* LISTEN
tcp 0 0 *:1040 *:* LISTEN
tcp 0 0 *:1025 *:* LISTEN
tcp 0 0 *:6000 *:* LISTEN
tcp 0 0 *:smtp *:* LISTEN
tcp 0 0 *:printer *:* LISTEN
tcp 0 0 *:linuxconf *:* LISTEN
tcp 0 0 *:auth *:* LISTEN
tcp 0 0 *:finger *:* LISTEN
tcp 0 0 *:login *:* LISTEN
tcp 0 0 *:shell *:* LISTEN
tcp 0 0 *:telnet *:* LISTEN
tcp 0 0 *:ftp *:* LISTEN
tcp 0 0 *:sunrpc *:* LISTEN


This output shows that all servers are simply waiting for an incoming connection. Here’s some more interesting data from these options:
>netstat –tw
Active Internet connections (w/o servers)
Proto Recv-Q Send-Q Local Address Foreign Address State
tcp 0 1 g69-17.citenet.net:1063 cti13.citenet.net:finger SYN_SENT

  • Recv-Q represents the count of bytes not copied to this citenet.net socket.
  • Send-Q represents the count of bytes not acknowledged by citenet.net.

Displaying program connections
In order to display program connections with netstat, you use the -p option. A sample readout is shown here:
>netstat –p
Active UNIX domain sockets (w/o servers)
Proto RefCnt Flags Type State I-Node PID/Program name Path
unix 1 [ ] STREAM CONNECTED 6974 554/gnome-smproxy @00000082
unix 1 [ ] STREAM CONNECTED 1622 615/asclock_applet @0000007b
unix 1 [ ] STREAM CONNECTED 1309 601/gmc @0000006a
unix 1 [ ] STREAM CONNECTED 593 512/X @0000003f
unix 0 [ ] STREAM CONNECTED 201 1/init [5] @0000002e
unix 1 [ ] STREAM CONNECTED 6712 663/xemacs @00000081
unix 1 [ ] STREAM CONNECTED 1324 601/gmc @0000006b
unix 1 [ ] STREAM CONNECTED 589 513/ @0000003e
unix 1 [ ] STREAM CONNECTED 1667 592/panel @00000080
unix 1 [ ] STREAM CONNECTED 677 558/ @0000004b
unix 1 [ ] STREAM CONNECTED 46050 554/gnome-smproxy @000000b7
unix 1 [ ] STREAM CONNECTED 1647 592/panel @0000007f
unix 1 [ ] STREAM CONNECTED 1595 615/asclock_applet @00000077
unix 1 [ ] STREAM CONNECTED 1465 612/gen_util_applet @0000006e
unix 1 [ ] STREAM CONNECTED 1294 601/gmc @00000068
unix 1 [ ] STREAM CONNECTED 1112 592/panel @0000005d


This readout shows that all the programs are connected with their PIDs and their names (Program name). All of the programs are connected to UNIX sockets.

Why use netstat?
Why would anyone want to use netstat? The answer is to debug networks. You might use this tool if you suspected that your network was sluggish. This tool becomes the next logical step in debugging a network. After using ping, I’d use netstat to check all network connections.

Scenario
You’re on a network and supposedly connected to the Internet. Your boss comes in and yells at you because the e-mail server isn't working.

Here’s one strategy you can use to find out why it isn’t working. First, check the routing table. Do you still have a network? You can find out by issuing the command netstat -nr. If, in the Flag column, a U appears for all the interfaces in the Iface column, then you’re in luck—your network works. If not, you have a problem. You must check each interface and reinstall it using ifconfig and route or some similar tool.

Next, do a general packet check. This check will display general information in a list format as shown here:
Use netstat –s
Ip:
8285 total packets received
0 forwarded
0 incoming packets discarded
120 incoming packets delivered
8252 requests sent out
Icmp:

Tcp:
515 active connection openings
0 passive connection openings
0 failed connection attempts
0 connection resets received
0 connections established
8158 segments received
8120 segments sent out
117 segments retransmitted
39 bad segments received
150 resets sent
Udp:


Check the tcp section, and look at the segments’ received rates. If the rates are low, the problem could exist within your network, or maybe it’s just that you’re on a slow line. If there’s simply a lot of traffic, then you can tell your boss to send the e-mail later.

If the number of failed connection attempts is high, then your ISP is most likely causing the problem. You can reboot the computer if you're on a Microsoft network.
Rebooting on a Linux network is not necessary.
After this, you might try issuing netstat -i. I discussed this option in a previous section. You’d want to use this option to inspect the RX-OK, RX-ERR, RX-DRP, TX-OK, TX-ERR, and TX-DRP packet metric values. If RX/TX-ERR is near zero, then you’re in good shape. If the RX-ERR value is high, the problem is line speed, the ISP, or traffic. If the TX-ERR value is high, then the problem could be your network. You’ll need to clean the cables and check all the routes.

Where would you apply netstat? You’d use netstat on the main e-mail server or any server that uses the Internet heavily. It could be used on a LAN not connected to the Internet, but the traffic should be fairly constant. In that case, you’d then use netstat -n to check your UNIX connections. This will show which streams are connected.

whois
The whois tool will give you addresses and information related to an Internet address, which is useful for security purposes. You can use it as a first line of defense against crackers if you can get their ISP number. Then, you can call up the ISP and complain!

Use the following command at the prompt to invoke whois:
whois .|com|net|org|edu

For example, whois xoom.com yields the following information:
#whois xoom.com
[rs.internic.net]
Whois Server Version 1.1
Domain names in the .com, .net, and .org domains can now be
registered with many different competing registrars.
Go to http://www.internic.net for detailed information.
Domain Name: XOOM.COM
Registrar: NETWORK SOLUTIONS, INC.
Whois Server: whois.networksolutions.com
Referral URL: www.networksolutions.com
Name Server: NAME.PHX.FRONTIERNET.NET
Name Server: NAME.ROC.FRONTIERNET.NET
Name Server: NS1.XOOM.COM
Name Server: NS2.XOOM.COM
Name Server: NS3.XOOM.COM


This information isn’t too interesting in itself, but it’s also useful for the next network tool.

Why use whois?
If you suspect that your network is being hacked, whois can give you the name of the ISP or their main branch. This is the ethical reason for using this tool. Another use is to get information on computers that access your server.

Let’s suppose that weird_do.org hacked your system. If you type:
whois weird_do.org

you'll see something like this:
[rs.internic.net]
Whois Server Version 1.1
Domain names in .com, .net, and .org can now be
registered with many different competing registrars.
Go to http://www.internic.net for detailed information.
WEIRD_DO.ORG.TOM_GUN.ORG
WEIRD_DO.ORG
OR
Domain Name :WEIRD_DO.ORG
Registrar: TOM_GUN.ORG
Whois Server:whois.TOM_GUN.org
Referral Server:whois.TOM_GUN.org
Referral URL: www.TOM_GUN.org
Name Server:NS1.WEIRD_DO.ORG
Name Server: NS2:WEIRD_DO.ORG
Update Date: 23-july-1999


You can also use whois for purposes other than security. This is very similar to the previous example. For instance, the site oceania.org has a link that will tell you what server you’re using as the browser and your screen resolution. It’s obvious that they’re using whois in a creative fashion.

nslookup
Another major network tool is nslookup. You can use this tool to verify the operation of your name server; nslookup allows you to search for all kinds of data relating to a name server. You can look up mail records (MX), NS records (records associated with the root domain), and Start Of Authority (SOA) records, just to name a few. And, nslookup works in two modes: interactive and non-interactive. So, to get these records to appear, at the interactive prompt, you’d type set type=MX for mail records, followed by the name of the name server (yours or another company for which you’d like to see MX records). A good use of nslookup is on an e-mail server. If people can't send their e-mail, perhaps the server is offline. Invoke nslookup to check on the status of a remote e-mail server in general and to check the MX records in particular. Possibly the company is going through changes, which could cause e-mail problems on the client's end.

Let’s look at the interactive mode. There are many options for this command—too many to look at them all. The nslookup command-line form is:
nslookup [-option,,,] [host-to-find | [-server] ]

For example, invoking nslookup at the prompt yields the following:
> nslookup xoom.com
Server: g29-151.citenet.net
Address: 205.151.205.151
Non-authoritative answer:
Name: xoom.com
Address: 206.132.179.136


The non-authoritative answer means that xoom.com isn't the official domain name used for this server. If you type nslookup at the prompt, the following occurs:
> nslookup
Server: g29-151.citenet.net
Address: 205.151.205.151


At this prompt, you type in the domain name, and it will respond with the name and address.

Suppose you now want to look up MX records. At the nslookup prompt, you type >set type=MX:
>set type=MX
> xoom.com
Server: g29-151.citenet.net
Address: 205.151.205.151
xoom.com preference=10 mail exchanger=mail4.xoom.com
xoom.com preference=0 mail exchanger=mail1-mx2.xoom.com
xoom.com preference=0 mail exchanger=mail1-mx3.xoom.com
xoom.com nameserver=ns1.xoom.com
xoom.com nameserver=ns2.xoom.com
xoom.com nameserver=name.roc.globalcenter.net
xoom.com nameserver=name.pbx.globalcenter.net
mail4.xoom.com internet address=206.57.66.73
mail1-mx2.xoom.com internet address=206.57.66.72


One other interesting use of nslookup is to look up SOA records. Look at this example:
>set type=SOA
xoom.com
Server: g29-151.citenet.net
Address: 205.151.205.151
Non-authoritative answer:
origin=lugh.xoom.com
mail address=dns.xoom.com
serial=20000011300
refresh=10800
retry= 1800
expire= 604800
minimum ttl=3600
Authoritative answers can be found from:
xoom.com nameserver=ns1.xoom.com
xoom.com nameserver=ns2.xoom.com
xoom.com nameserver=name.roc.globalcenter.net
xoom.com nameserver=name.pbx.globalcenter.net
xoom.com nameserver=ns1.nuq1.gctr.net
ns1.xoom.com internet address=206.132.185.58
ns2.xoom.com internet address=206.132.185.59
name.roc.globalcenter.net internet address=206.130.187.10
name.pbx.globalcenter.net internet address=206.165.6.10
ns1.nuq1.gctr.net internet address=206.216.163.20.


Another interesting thing you can do is use the d2 option to print extensive debugging information about your network if it gets gummed up.

Why use nslookup
Why would you want to use nslookup? This tool checks to see if your domain name server is in working order. It’s also good for finding information on other domain name servers. In all, it’s an extremely versatile tool.

There is an interesting use of finger in nslookup. Once the host is defined, you can use finger to check to see whether certain users exist on that machine if a finger server exists on the remote machine to which you’re connecting.

For debugging your own server, you can use the d2 and debug options. In interactive mode, enter the following:
>set debug
>set d2
> xoom.com
Session looks like
;;res_nmkquery(QUERY,xoom.com,IN,A)
---------
SendRequest, len 26
HEADER:
opcode=QUERY,id=51423 rcode=NO ERROR
header:FLAGS, query:want recursion
questions= 1, answers=0, authority, records=0, additional=0

QUESTION:
xoom.com, type=A class=IN
----------
----------
Got answer (248 bytes)
opcode=QUERY,id=51423 rcode=NO ERROR
header:FLAGS, query:want recursion
questions= 1, answers=1, authority, records=5, additional=5

QUESTION:
xoom.com type=A class =IN
ANSWERS:
-> xoom.com
type=A class=IN, dlen=4
internet address=206.132.179.136
ttl:2488(41m28s)
AUTHORITY RECORDS:
-> xoom.com
type=NS,class=IN, dlen=6
nameserver=ns1.xoom.com
ttl=545(9m5s)

ADDITIONAL RECORDS
->ns1.xoom.com
type=A class=IN, dlen=4
internet address=206.132.185.59
ttl:145483

->name.roc.globalcenter.net
type=A class=IN, dlen=4
internet address=209.130.187.10
ttl:2488(41m28s)
-------------
Server:xoom.com
Address:206.132.179.136
---------------


If your name server is messed up, your report will look similar to the report shown above. This example is meant to be instructive (in case you’ve never seen what the debug information looks like).

Scenario
Back to the scenario where your boss is yelling at you because the e-mail server isn't working. You can enter the following at the prompt (let’s say that the name of your ISP is boring_biz.net):
>nslookup
>>set q=mx

mail1-mx1.boring_biz.net internet address=201.00.34.23
mail2-mx2.boring_biz.net internet address 201.01.35.24

>>set q=any
>>mail2

Server: boring_biz.net
Address: 200.00.22.21


If you get this response
mail2:can’t find 201.00.34.23: non-existent host/domain

then your network has problems!

Your next step is to check to see if your network is up. Go into nslookup again (I’m assuming you exited it), and type
>nslookup
>>set q=any
>> .com, = your company's name


You should see
Server :.com
Address:xxx.yyy.zzz.aaa


If not, you have a problem. If you do see it, then at the prompt run:
>>set q=mx
>>.com


You should see a listing something like this:
mail-mx1..com internet address=bbbb.cccc.dddd.eeee
...


If not, there’s still a problem. Check the cables of your mail server or network card.

finger
The next tool is minor; finger has little use as far I can see. If you want to get the address or phone number of someone, then finger will be able to do it, assuming that you’re allowed access to the remote finger server.

The command-line structure of finger is
finger [-lmsp] [user...] [user@host...]

To best see how finger works, let's invoke it. At the prompt, type:
>finger –s

and you should see something like this:
Login Name Tty Idle Login Time Office Office Phone
kabir Larry Mintz 4 * Dec 24 20:46 (xxx)yyy-zzzz


Why use finger?
As far administration goes, finger doesn't really give much useful information. If you forgot the number of a user whose login name is hog, type:
>finger -s hog

which should report something like this:
Login Name tty idle login time Office Office #
hog Hoggish Greedly 3 * 9:15 WB34-1 666-6666


Conclusion
So many network tools exist to aid you in your network administration load. In this Daily Drill Down, I’ve shown how Linux (like UNIX) bears this weight with the help of a very powerful, yet simple-to-use set of network tools. These tools, ping, netstat, whois, nslookup, and finger, report a great deal of information to the administrator.

Larry Mintz is a Canadian citizen who does contract work on many levels. Larry holds a B.A. in mathematics from Concordia University, studies theoretical math, and has written solution manuals for many texts.

The authors and editors have taken care in preparation of the content contained herein but make no expressed or implied warranty of any kind and assume no responsibility for errors or omissions. No liability is assumed for any damages. Always have a verified backup before making any changes.

Thanks : articles.techrepublic.com