ServerXchange Troubleshooting Guide 1
Troubleshooting ServerXchange
This document includes common problems and instructions for resolving them, tips for using Ensim ServerXchange™, error messages, and references to other helpful resources.
While using ServerXchange, you might encounter problems with the following hardware or software components:
• Physical layers
• Operating system (see“Operating system” on page 6) • Network (see“Network” on page 12)
• Physical Servers (see“Physical servers” on page 19)
• NFS services (see“Sharing directories using NFS” on page 20)
Physical layers
The physical layers of ServerXchange consist of the hardware components. This section tells you what to check if you suspect a problem with the physical layers of:
• ControlCenter™ • Solaris system® • Red Hat® system
Table 1. Problems with physical layers
What to check Why How to verify
Power supplies
ControlCenter You should have two power supplies, both of which should be plugged in. If one power supply is not plugged in, the system will not start completely until you press F1.
On the front of
ControlCenter, you will see the Power LED glow yellow/amber.
When you turn on the system, the light will turn green, and you will hear the fans and drives start up.
Solaris or Red Hat
The physical server needs power to operate.
Be sure the power cable is plugged into both the system and your power outlets.
Physical layers
ServerXchange Troubleshooting Guide 3
Network cabling
ControlCenter ControlCenter needs network access to your Physical Servers and the Internet.
Make sure an RJ-45 Cat 5 straight-through ethernet cable is plugged into ControlCenter.
The other end of the cable should be
connected to the rest of your LAN (through a hub, switch, or other device).
If the network cable to ControlCenter is working, you will see the green link LED glow on the back of ControlCenter, just above the cable connection.
If your hub/switch has LED readouts, they should show a link ready (usually a green light) for the port that your physical server is plugged into.
Solaris or Red Hat
The physical servers must have network access.
Table 1. Problems with physical layers (continued)
Console monitor and keyboard
The console monitor displays messages as the system starts. You might also want to use the console to configure your ControlCenter’s initial IP information.
For ControlCenter:
If your console is correctly plugged in, you will see the Power-on Self Test (POST) messages,
followed by Red Hat Linux startup messages.
If your keyboard is
correctly plugged in, you should be able to log in with the ccadmin/admin login to configure your ControlCenter’s initial IP information.
For Solaris and Red Hat:
If your console and keyboard/mouse are properly plugged in, you should see the Sun
Desktop login screen, or a white screen with a login prompt.
If you start a Sun system without a Sun keyboard, the system will use Serial port A for its input/output.
To use a Serial console, you need either a real serial terminal (such as a VT100), or another
Table 1. Problems with physical layers (continued)
Physical layers
ServerXchange Troubleshooting Guide 5
System type
Solaris Your system must be running the SPARC version of Solaris. Solaris for x86 is not supported.
The Solaris system should say sun4x, where x can be a different letter.
If your system shows the Sun name and logo, it most likely uses a SPARC CPU. To verify this, use the command uname -p. The output should be sparc.
Red Hat Your system must be running the x86 version of Red Hat Linux 6.1. Red Hat Linux for other types of platforms (such as SPARC or PPC) are not supported.
Type cat /proc/cpuinfo. The output should list an x86-compatible CPU. Or type
uname -m. The output
should say i686.
SMTP server IP address
ControlCenter periodically sends email messages to the administrator. You must provide a valid SMTP server IP address for
ControlCenter to send mail through.
Verify the IP address with your network
administrator.
Table 1. Problems with physical layers (continued)
Operating system
Table 2lists what to check if you suspect a problem with the Solaris or Red Hat operating system.
Table 2. Problems with the operating system
What to check Why How to verify
Root password You will need to perform many tasks reserved only for the root user.
Log in as root at the console. If you do not know the root password, obtain it from your system administrator.
Nonroot user login to the Physical Server
You will need this account to register the Physical Server in ServerXchange.
Log in with the user name and password.
Note: The account does not have to be local to the system. If you use NIS/NIS+/LDAP, you will be authenticated by another server.
Operating system
ServerXchange Troubleshooting Guide 7
64-bit mode (Solaris)
ServerXchange requires that your Solaris system operate in 64-bit mode.
To support 64-bit Solaris 7, your system must be running OpenBoot PROM 3.11 or later. To determine your OpenBoot PROM version, type /usr/platform/<sun_arch>/
sbin/prtdiag -v.
where <sun_arch> is the type of Sun system you have. For example, Sun Ultra class machines are sun4u.
If you do not know your architecture type, use this command:
uname -m
If you have a version of OpenBoot PROM that is older than 3.11, consult your Sun documentation on flashing the PROM to a newer version.
Kernel version (Red Hat) ServerXchange requires a kernel level of 2.2.12-20 to install the software.
Type uname -r. The output should show the kernel level.
Table 2. Problems with the operating system (continued)
Physical memory
Solaris Your Solaris system requires at least 128 MB of memory to effectively run ServerXchange. Type /usr/platform/<sun_arch>/ sbin/prtdiag -v.
where <sun_arch> is the type of Sun system you have. For example, Sun Ultra class machines are sun4u.
If you do not know your architecture type, use this command:
uname -m
In the output from prtdiag, you will see a value called Memory Size.
Red Hat Your Linux system requires at least 128 MB of memory to
effectively run ServerXchange.
Type free. You should see at least 256 MB listed below the total amount of memory.
Table 2. Problems with the operating system (continued)
Operating system
ServerXchange Troubleshooting Guide 9
Swap space Ensim recommends at least 256 MB of swap space for a system with 128 MB of physical memory.
Memory for ServerXchange Private Servers is allocated from the combined memory resources of physical
memory and swap. Make sure you have enough total memory (physical memory + swap) to accommodate your Private Servers.
For Solaris:
To determine how much swap space is on your Solaris system, type df -k swap or
swap -s. For Red Hat:
Type free. You should see at least 256 MB listed below the total amount of memory.
Disk space
Solaris ServerXchange requires at least 4 GB of total disk space, with at least 1GB in /var/spool/pkg/.
To see how much space is available on all the partitions on your system, type df -k.
Red Hat ServerXchange requires at least 10 GB of total disk space.
Table 2. Problems with the operating system (continued)
Base operating system
Solaris ServerXchange requires a minimal base OS to install the software. The minimum is Solaris 7, with End-User
distribution or greater.
Be sure all required Solaris packages (as listed in the
ServerXchange User Guide)
are present on your system. Type pkginfo to list the packages on your Solaris system.
Red Hat ServerXchange requires the following
environment in which to install the software:
Red Hat 6.1 with the Networked Workstation package + sharutils (contained in the Mail/ WWW/News Tools package)
Verify the base operating system with your system administrator.
If you did not install Red Hat 6.1 with Mail/WWW/News Tools, then you need to install sharutils.x.x.x.rpm by hand. To verify that the sharutils have been installed, type
rpm -q sharutils
You should see sharutils-x.x.x listed.
If the sharutils have not been installed, copy the
sharutils.x.x.x.rpm from your Red Hat Linux 6.1 CD (or archive) and install it with the command:
rpm -ivh sharutils.x.x.x.rpm Table 2. Problems with the operating system (continued)
Operating system
ServerXchange Troubleshooting Guide 11
Solaris environment
ServerXchange requires a clean 11/99 Solaris 7 environment in which to install the software.
Type uname -v or
showrev -p.
If you do not see
Generic_106541-08, then you must re-install your Solaris system.
Note: Do not apply any Sun cluster or
recommended patches after the 11/99 is installed.
Sun OS Headers package
This package contains files required by ServerXchange to operate properly.
Type pkginfo SUNWhea. If you do not see system
SUNWhea SunOS Header Files, then you must install this package.
Table 2. Problems with the operating system (continued)
Network
Table 3lists what to check if you suspect a problem with the network.
Table 3. Problems with the network
What to check Why How to verify
IP address
ControlCenter In order for you to communicate with your ControlCenter or for your ControlCenter to be able to communicate with the rest of your systems, it needs a valid IP address on your LAN.
Verify the IP address with your network
administrator.
Physical server In order for you to communicate with your physical server or for your physical server to be able to communicate with the rest of your systems, it needs a valid IP address on your LAN.
Type ifconfig -a to view the current IP settings for your system.
If you do not know if the settings are correct, consult your network administrator.
Network
ServerXchange Troubleshooting Guide 13
Router/gateway IP address
ControlCenter For ControlCenter to communicate properly with the rest of your network, you need the correct router (or
gateway) address for the network on which your ControlCenter resides.
Verify the IP address with your network
administrator.
Table 3. Problems with the network (continued)
Physical server For the physical server to communicate properly with the rest of your network, you need the correct router (or
gateway) address for the network on which your physical server resides.
Type netstat -rn. One of the entries under Destination may say default. The corresponding Gateway address for that entry is the router IP address for your system.
Note: It is possible to have no router IP address if you are running a routing daemon, such as routed or gated. It is also possible to have multiple default gateway entries.
Make sure your Physical Server can ping the IP address of your gateway.
For more help on verifying the IP address, consult your network administrator.
Subnet mask
Table 3. Problems with the network (continued)
Network
ServerXchange Troubleshooting Guide 15
ControlCenter For ControlCenter to communicate properly with the rest of your network, you need the correct subnet mask for your ControlCenter.
Verify the subnet mask with your network administrator.
Physical server For the physical server to communicate properly with the rest of your network, you need the correct subnet mask for your physical server.
Verify the subnet mask with your network administrator.
Internet connectivity
ControlCenter must be able to reach the Internet during the end of the registration process, when it validates its information with the Ensim registration server.
ControlCenter should be behind your firewall. If it is, be sure the IP address of ControlCenter is allowed to go outside the firewall.
Verify the IP address with your network
administrator.
DNS servers
Table 3. Problems with the network (continued)
ControlCenter To properly reach other systems on your network and on the Internet, ControlCenter must have a valid DNS server to use for looking up host name IP addresses.
Verify the DNS server with your network
administrator.
Physical server To properly reach other systems on your network and on the Internet, the physical server must have a valid DNS server to use for looking up host name IP addresses.
Verify the DNS server with your network
administrator.
DNS entry
Table 3. Problems with the network (continued)
Network
ServerXchange Troubleshooting Guide 17
ControlCenter The host name IP address for your ControlCenter must be properly defined in your DNS servers.
Use the UNIX/DOS command nslookup to verify that your DNS server has been properly
configured with ControlCenter information. Your nslookup session might look something like the following: > nslookup > server 192.168.1.3 Default Server: [192.168.1.3] Address: 192.168.1.3 > cc.domain.com Server: [192.168.1.3] Address: 192.168.1.3 Non-authoritative answer: Name: cc.domain.com Address: 192.168.1.2 > 192.168.1.2 Server: [192.168.1.3] Address: 192.168.1.3 Name: cc.domain.com Address: 192.168.1.2
Physical server The host name IP address for your physical server must be properly defined in your DNS servers.
Table 3. Problems with the network (continued)
SMTP server IP address
ControlCenter will be sending email messages to the administrator on occasion. You must
provide a valid SMTP server IP address for
ControlCenter to send mail through.
Verify the IP address with your network
administrator.
Administrator’s email address
ControlCenter will be sending email messages to the administrator on occasion. You must provide a valid email address for the administrator.
Verify the email address with your network administrator.
FTP server IP address
ControlCenter periodically backs up the data about your Physical and Private Servers, your Customers, and the Services you have installed.
Verify the IP address with your network
administrator.
FTP login and password
In order for ControlCenter to perform backups, you must have a valid login to your FTP server.
Verify the login and password with your network administrator.
You should be able to start an FTP session to the IP address of your FTP server and log in with this login and password.
Table 3. Problems with the network (continued)
Physical servers
ServerXchange Troubleshooting Guide 19
Physical servers
If you suspect a problem with the physical servers, verify that your systems meet the following minimum configuration requirements for use with ServerXchange.
Solaris
• At least 128 MB of physical RAM • At least 4 GB of disk space
• A clean installation of Solaris7 (11/99 revision)
• At least an End-User Distribution with the package SUNWhea (SunOS Header Files)
You can also install a Developer Distribution or higher (Full or Full with OEM) if you prefer.
• Installed 64-bit support
Linux
• Pentium® III CPU, 500 MHz or higher (single processor) • 256 MB of RAM
• Any NIC supported by Red Hat 6.1
Important: Do not install an older version of Solaris7 (such as 5/99) and apply any maintenance updates.
Note: Only machines that are running OpenBoot PROM 3.11 or later will support 64-bit Solaris7.
To determine if you have the correct type of Sun system, type
uname -m. The response should show the architecture
designation sun4u. This includes any Sun Ultra (2,5,10, and so on) system and later.
• At least 10 GB disk space (IDE, SCSI device, and SCSI adapter must be supported by Red Hat 6.1)
• Red Hat 6.1 with a minimum of: • Networked workstation package
• sharutils (or select Mail/WWW/News tools package)
• (Optional) Raid Device (must be supported during Red Hat installation)
Sharing directories using NFS
By default, Solaris and Red Hat systems do not share any directories through NFS. To set up NFS sharing, use the instructions in the following sections.
Solaris
Use the following instructions to set up NFS sharing on a Solaris system.
1 Edit the file /etc/dfs/dfstab to include the directories you are sharing and the options and restrictions to apply to sharing (if any).
For example, you might use ps92.ops as the NFS server and ps91.ops as the NFS client. The /etc/dfs/dfstab file should contain the following line (all one line):
Sharing directories using NFS
ServerXchange Troubleshooting Guide 21
share -F nfs -o root=ps91.ops.ensim.com -d “export for PS” /export/sxc
This command sets up sharing /export/sxc from ps92.ops to ps91.ops. The root= flag specifies that the host(s) listed after it are allowed root access through NFS. (See the share man pages for more options.)
2 Log in as root using the command su -.
3 Start the NFS server process (if is not already running) with the following command:
<NFS_server_name># /etc/init.d/nfs.server start
When the system starts, nfs.server is run (in /etc/rc3.d/). The script starts the NFS server daemon only if it finds an entry in /etc/dfs/dfstab.
4 After you successfully run nfs.server start, type dfshares to make sure that the server is sharing the directories you listed in /etc/dfs/dfstab.
The return should look similar to the following:
ps92.ops# dfshares
RESOURCE SERVER ACCESS TRANSPORT ps92.ops:/export/sxc ps92.ops -
-Using NFS to mount this directory on another system 1 Create a mount point if necessary on the client server:
a Typemkdir /mnt/export
b Typemount ps92.ops:/export/sxc /mnt/export
Important: On a Solaris NFS server, you must set the root= flag for specific Physical Servers. Private Servers should never be given root access to the NFS partition; it will compromise the security of other Private Servers installed in that location.
If you do not set root access for the NFS client, it will fail when trying to create a Private Server in that NFS directory. It needs to be able to create files there as root.
2 Use df -k to make sure the directory is mounted. On the client server, type df -k
The return should look similar to the following:
Filesystem kbytes used avail capacity Mounted on /proc 0 0 0 0% /proc /dev/dsk/c0t0d0s0 8445522 757324 7603743 10% / fd 0 0 0 0% /dev/fd swap 506064 16 506048 1% /tmp ps92.ops:/export/sxc 8445522 907490 7453577 11% /mnt/ export
3 Use the dfmounts command to see which NFS clients are currently mounting directories from the NFS server.
On the NFS server, type ps92.ops# dfmounts The return should look similar to the following:
RESOURCE SERVER PATHNAME CLIENTS
- ps92.ops /export/sxc ps91.ops.ensim.com
Linux
Use the following instructions to set up NFS sharing on a Linux system. 1 Verify that NFS RPM is installed on your system by typing rpm -q knfsd.
This command should return:
knfsd-1.4.7-7
2 If NFS RPM is not installed, use the following steps to install it from the Red Hat CD-ROM.
a As root, typepwd.
b Type/mnt/cdrom/RedHat/RPMS c Typerpm -ivh knfsd-1.4.7-7.i386.rpm 3 Do one of the following:
Solaris tips
ServerXchange Troubleshooting Guide 23
• Run the netconf utility. or
• Edit /etc/exports.
The entries in the file should be similar to the following (all on one line):
/export/ensim linux5(no_root_squash) linux6(no_root_squash) sun4(no_root_squash)
4 Start the NFS server process with the following command: <NFS_server_name># /etc/rc.d/init.d/nfs. start
To stop the NFS server process, use the following command: <NFS_server_name># /etc/rc.d/init.d/nfs stop
Solaris tips
This section contains Solaris commands and tips for using ServerXchange.
Booting the system from CD-ROM
If you have root access, you can boot the system from the CD-ROM with this command:
Note: Each time you change /etc/exports, you must restart the NFS daemon by typing /etc/rc.d/init.d/nfs restart
Important: Private Servers should never be given root access to the NFS partition; it will compromise the security of other Private Servers installed in that location. If you do not set root access for the NFS client, it will fail when trying to create a Private Server in that NFS directory. It needs to be able to create files there as root.
On a Linux NFS server, you must disable root_squash for use with ServerXchange Physical Servers.
# reboot -- cdrom
If the keyboard is attached to a Sun system, you can also force the system to boot from the CD-ROM by pressing Stop+a. The OpenBoot PROM prompt > appears. At the prompt, type:
Solaris tips
ServerXchange Troubleshooting Guide 25
Installing the operating system
When you install Solaris 2.7, the installation script will ask you what type of system configuration you want to install.
• Full Distribution plus OEM support • Full Distribution
• Developer System Support • End User System Support • Core System Support
Select any option except Core System Support.
If you select End User System Support, you must click Customize to add the SunOS Header Files package to the installation list. If you do not, you will have to manually pkgadd SUNWhea after the operating system is installed.
The following options already include the SunOS Header Files. • Full Distribution plus OEM support
• Full Distribution
• Developer System Support
The installation can take anywhere from 20 minutes to two hours, depending on what option you are installing and how fast the CD-ROM and hard drives are. Partitioning the system
To partition the system, it is usually easier to use the Autolayout option, and then edit the partitions and sizes.
Autolayout usually allocates the majority of the disk to /export/home. This partition is not necessary unless you are going to locate many users there. Feel free to delete it and spread the free disk space to the other partitions.
If a local partition will be used to store the Private Servers (such as/export, /usr/ ensim), the partition should be large enough to support the number and size of the Private Servers planned. Anywhere from 500 to 1000 MB+ per Private Server might be needed.
Table 4lists the partitions and their recommended sizes.
Console
If a Sun system is booted headless, you cannot plug in a monitor (VGA or Sun) afterwards to get console access. When the system does not detect a keyboard at startup, it will use Serial port A as its console.
Table 4. Partition size (Solaris)
For this partition: Specify:
/ At least the Autolayout default (~93 MB for an End-User install). If any patches will be applied (especially the cluster patch), be sure there is enough room in this partition for the patches. How much extra space is needed depends on what is already installed; however, according to Sun, you should have at least 4 MB free in /, /usr, /var, and /opt before attempting to install the cluster patch.
swap At least 256 MB for a production system. Make swap larger if more total memory will be needed to support the Private Servers.
/usr (optional) At least the auto-layout default.
/var (optional) At least 500 MB to store the Ensim packages. In addition, if the log files grow very large, you might want to isolate them in their own partition to avoid filling up the root partition.
Solaris tips
ServerXchange Troubleshooting Guide 27
Networking tips
IP address/netmaskTo change the IP/netmask on a Solaris system, use the ifconfig command: ifconfig hme0 inet 192.168.1.5 netmask 255.255.255.0
You can configure the default netmask the system uses at startup in /etc/netmasks.
To automatically set the host name/IP at startup, add an entry in /etc/hosts. Then add the host name to /etc/hostname.hme0.
To change the host name of the system without rebooting, use the hostname command as follows:
hostname newhostname DNS
If you encounter problems resolving host names, verify that /etc/resolv.conf has a nameserver entry and a search domain entry (if appropriate):
nameserver 192.168.1.3
search ensim.com ops.ensim.com
Also, in /etc/nsswitch.conf, the hosts line should reflect the order in which host names should be looked up. For example, dns should be first if you want the DNS server to be queried first; hosts should be first if you want the local hosts file to be queried first.
To set the default domain, create a file called /etc/defaultdomain and include the default domain in it.
Routing
To add a gateway, use the following command. route add net default 192.168.1.1
To delete a gateway, use the following command. route delete net default 10.0.0.1 1
To make the gateway address permanent between reboots, add the gateway IP address to /etc/defaultrouter. You can also use a host name, but be sure it is defined in /etc/hosts first (name services are not running when the route is added).
To see the routing table, use the netstat -rn command. Common command locations
• pingis in /usr/sbin/ping.
• nslookupis in /usr/sbin/nslookup. • ifconfigis in /sbin/ifconfig.
Adding users
Use the useradd command to add users: useradd admin
passwd admin
Using CD-ROMs and diskettes
By default, Solaris automounts CD-ROMs when you insert them. The volume daemon that does this is vold. If the daemon is not running, it will not automount the CD-ROM. After Solaris Physical Servers have been registered and restarted, they will not be running the vold daemon.
To restart vold, use the following command. /etc/init.d/volmgt start
To eject a CD-ROM, use the following command. eject
Solaris tips
ServerXchange Troubleshooting Guide 29
Adding and viewing packages
The Solaris equivalent of an RPM is a package. To add packages, use the following command.pkgadd -d <directory containing packages>
To add SUNWhea packages from the spool (/var/spool/), use the following command.
pkgadd -s SUNWhea
To remove packages, use the following command. pkgrm <packagename>
To list all packages, or specific packages, use the following command. pkginfo
pkginfo SUNWhea
Daemons
• Main system startup scripts reside in /etc/rc2.d/*. • Edit /etc/inetd.conf for inetd settings.
• Edit /etc/init.d/* scripts for startup scripts.
Log files
• /var/adm/*
• /var/adm/messages • /var/adm/sulog
Memory management (swap)
You can add more swap space from either an existing swap partition or from swap files you create on the fly.
1 Use the mkfile command to add space from an existing swap partition. mkfile 150m /opt/swapfile1
This command creates a 150 MB file. You can also use g/k/b for GB/KB/B. 2 Use the swap command to add it to the swap space on the fly.
swap -a /opt/swapfile1 or
swap -a /dev/dsk/c0t5/d0/s1
(or whatever slice the swap partition is at) To list swap files in use, use the swap -l command.
swap -l
The command returns data similar to the following:
/dev/dsk/c0t0d0s3 136,3 16 512048 491216 /opt/swapfile1 - 16 10224 10224
To display the current swap usage statistics, use the swap -s option. To include a swap file in the swap space at startup, add the swap file to /etc/vfstab, with the following fields.
Device: /opt/swapfile1 FS type is:swap
Mount at boot: no
Linux tips
ServerXchange Troubleshooting Guide 31
Linux tips
This section contains Linux commands and tips for using ServerXchange.
Booting the system from CD-ROM
If a Linux system does not automatically boot from the CD-ROM, press F2 or Del to display the Setup window. From the Setup window, select the device the system boots from first (such as CD-ROM, diskette, or hard drive). After you save your changes, the system will reboot.
Installing the operating system
When you install Red Hat 6.1, the installation script will ask you what type of system configuration you want to install.
• Gnome workstations • KDE workstations • Server
• Custom
Select Custom. When the script lists the software packages, select: • Mail/WWW/News tools
• Networked Workstation
The installation can take anywhere from 20 minutes to two hours, depending on what option you are installing and how fast the CD-ROM and hard drives are.
Partitioning the system
Table 5shows the partitions and their recommended sizes.
If a local partition will be used to store the Private Servers (such as/export, /usr/ensim), the partition should be large enough to support the number and size of the Private Servers planned. Anywhere from 500 to 1000 MB+ per Private Server might be needed.
Table 5. Partition size (Linux)
For this partition: Specify:
/boot 50 MB
swap At least 256 MB for a production system. Make swap larger if more total memory will be needed to support the Private Servers.
/ The rest of the drive.
/usr (optional) At least 1 GB to support the default file system.
/var (optional) At least 1 GB to support the operating system.
Linux tips
ServerXchange Troubleshooting Guide 33
Networking tips
IP address/netmaskTo change network settings, use the netconf/linuxconf utilities or manually adjust the network files. To make temporary changes, use ifconfig/route commands at the command line. For example:
ifconfig eth0 inet 192.168.1.5 netmask 255.255.255.0
Ensim provides scripts to help automate adding and deleting IP aliases on Linux Private Servers.
/sbin/aifconfig alias IPADDRESS /sbin/aifconfig delete IPADDRESS
Use the following command to make the changes take effect. /etc/rc.d/init.d/network restart
To verify current network settings, look at the values in /etc/sysconfig/network. DNS
If you encounter problems resolving host names, verify that /etc/resolv.conf has a nameserver entry and a search domain entry (if appropriate).
nameserver 192.168.1.3
search ensim.com ops.ensim.com
Also, in /etc/nsswitch.conf, the hosts line should reflect the order in which host names should be looked up. For example, dns should be first if you want the DNS server to be queried first; hosts should be first if you want the local hosts file to be queried first.
Routing
To add a gateway, use the command:
route add default gw 192.168.1.1
To delete a gateway, use the command:
route del default gw 10.0.0.1 1
To see the routing table, use the command netstat -rn. Common command locations
• pingis in /bin/ping.
• nslookupis in /usr/bin/nslookup. • ifconfigis in /sbin/ifconfig.
Adding users
Use the useradd command to add users. useradd admin
passwd admin
Using CD-ROMs and diskettes
Table 6shows common commands for using CD-ROMs and diskettes.
Table 6. CD-ROM/diskette commands
To: Use this command:
Mount a CD-ROM mount /mnt/cdrom
Unmount a CD-ROM umount /mnt/cdrom
Eject a CD-ROM eject
Linux tips
ServerXchange Troubleshooting Guide 35
Adding and viewing packages
The Linux equivalent of a Solaris package is an RPM. To add an RPM, use the rpm command.Example:
rpm -ivh <rpm name>
To remove an RPM, use the rpm -e or rpm -uninstall command. Example:
rpm -e sharutils
rpm -uninstall <rpm name>
To list all RPMs on the system, use the following command. rpm -qa | more
To list a specific RPM, use the RPM name. rpm -q <rpm name>
To list the files related to an RPM, use the following command. rpm -q -l <rpm name>
Unmount a diskette umount /mnt/floppy
Format a diskette mkfs -t <fstype> /dev/fd0
Note: When uninstalling, use the RPM name, not the RPM file name.
Table 6. CD-ROM/diskette commands (continued)
Daemons
• Main system startup scripts reside in /etc/rc.d/rc3.d/*. • Edit /etc/inetd.conf for inetd settings.
• Edit /etc/rc.d/init.d/* scripts for startup scripts.
• To prevent daemons from starting when the server starts, use the following command.
chkconfig on/off <daemon_name>
Log files
• /var/log/*
• /var/log/messages • /var/log/sulog
Memory management (swap)
Linux kernel 2.2.12 will support up to eight swap partitions of 2 GB each. You need 1K of kernel memory per megabyte of swap space. Make sure that you allocate enough swap space when you install the server, swap partitions are faster than swap files. If you need to increase your swap space you can create swap files. To see swap areas, look in /proc/swaps.
To create a Linux swap area:
1 Create a swap file using a command such as: dd if=/dev/zero of=swapfile bs=1024 count=65536
2 Use the command mkswap to create the swap area: mkswap [-c] [-vN] [-f] device/file [size]
The size parameter is superfluous; it is used for backward compatibility. It specifies the size of the swap area in 1024-byte blocks. Do not omit device/file; mkswapwill use the entire partition or file if you do.
Linux tips
ServerXchange Troubleshooting Guide 37
Example:
mkswap -v1 /swap/swapfile 131072
This command makes a swap file called swapfile that is 128 MB in size. 3 Add the following line to your /etc/fstab file.
/swap/swapfile swap swap defaults 0 0
4 To begin using the swap area, use the swapon command. /sbin/swapon -a
If you have no errors, use the following command to see if the swapon command is running.
[root@ps199 /swap]# swapon -s
This command returns data similar to the following.
Filename Type Size Used Priority /dev/sda6 partition 610428 0 -3 /swap/swapfile file 131064 0 -4
ServerXchange log files
Table 7lists the ServerXchange log files.Table 7. ServerXchange log files
ControlCenter /etc/serverxchange
/var/log/vkman.log
vkman.log provides the most details, especially during the creation of Private Servers
/var/log/serverxchange/
/var/log/serverxchange/ctrl-*.log
ControlCenter Web GUI includes a section where you can view log entries generated by ControlCenter.
Physical server directory structure and Private Server file
ServerXchange Troubleshooting Guide 39
Physical server directory structure and
Private Server file locations
You can access the Private Server files and configuration information on the Physical Server in /ServerXchange. The /ServerXchange directory is a common destination for the file systems of Private Servers.
This directory includes the following sub-directories.
filesys services templates vkman vpses
The sub-directory vpses contains the files specific to each Private Server, identified by the server’s internal ID number (vknid). The subdirectory vpses shows the locations of the file systems.
Example:
Physical server /var/log/vkman.log
vkman.log provides the most details, especially during the creation of Private Servers
/etc/serverxchange/
/tmp/serverxchange.log
/var/log/serverxchange/ctrl-error.log
/var/log/messages (Linux)
/var/adm/messages (Solaris)
Other useful logs /var/log/maillog
/var/log/httpd/error_log
/var/log/httpd/suexec_log
/usr/lib/opcenter/var/Z2.log
/usr/lib/opcenter/var/error.log
lrwxrwxrwx 1 root other 20 Jul 9 12:31 2 -> /export/home/vpses/2 lrwxrwxrwx 1 root other 18 Jun 21 16:33 4 -> /usr/ensim/vpses/4
The following command lists the contents of vpses. [root@ps52 /ServerXchange]# ls -F vpses
The command returns:
39/ 41/ 42/
The data indicates that three Private Servers reside on this physical server, with the ID numbers of 39, 41, and 42.
To see the contents of Private Server 39, use the following command. [root@ps52 39]# ls -F
The command returns:
info/ services/ treeroot/ vnkBuilt
The directory info contains the configuration files, which are copies of the information that is stored in ControlCenter's database. You can temporarily change the values in these files; however, the changes will not be preserved between reboots and will not propagate to ControlCenter.
The directory treeroot is the virtual file system for the Private Server.
Troubleshooting commands for physical and
Private Servers
The following list of commands is useful for troubleshooting physical and Private Servers.
vklookup
This command shows you the configuration information for a Private Server. Each Private Server has an internal ID number that you will often see in path names or process listings.
To convert between the ID number and the name of the Private Server, use the vklookupcommand.
Troubleshooting commands for physical and Private
ServerXchange Troubleshooting Guide 41
vklookup -I <id>
vklookup -n host.domain.com
kickstart
To gain shell access to a Private Server from a Physical Server without using telnet or ssh, use the kickstart command.
/usr/sbin/kickstart -e <vknid> /bin/bash
This is analogous to the command su - username, but instead of switching into a user’s environment, you switch into that Private Server environment. You will be logged in as root, and you will see only the Private Server's file system.
ServerXchange error messages
The ServerXchange User Guide contains a complete list of ServerXchange error codes; however,Table 8lists some of the more common error messages you might see, and what to do about them.
Table 8. ServerXchange error messages
Error message What to do
Error 1: Unknown Error Verify that your system is installed with all the required operating system
packages or rpms.
On Linux systems, verify that you have installed sharutils.x.x.x.rpm.
On Solaris systems, verify that you have installed the SUNWhea (Sun OS Headers) package.
Error 1053: Dependencies failed, please see Services dependencies table.
Verify that all dependencies for the service have been installed. For
example, on Linux systems, you cannot install mod_perl until Apache has been installed.
To see the dependencies for each Service, right-click the Service name in OpCenter and select Properties. Scroll down to where it says Services
Other helpful resources
ServerXchange Troubleshooting Guide 43
Other helpful resources
ServerXchange links• Ensim Support page: http://www.ensim.com/support
• Ensim Support Knowledge Base: http://www.ensim.com/kb (requires your customer login and password)
• External FAQ: http://www.ensim.com/faq (requires your customer login and password)
• Ensim Manuals/Release Notes: http://www.ensim.com/documentation (requires your customer login and password)
Solaris/Sun links
• Sun Web page: http://www.sun.com
• Sunsolve (patches, knowledge base, bug reports): http://sunsolve.sun.com • Sun documentation (includes all Solaris publications, admin guides,
manuals): http://docs.sun.com • Third-party Sun sites:
http://www.sunhelp.org http://www.sunfreeware.com
http://www.ibiblio.org/pub/packages/solaris/sparc/ Linux links
• Red Hat Linux Web page: http://www.redhat.com • Linux Online: http://www.linux.org
• Linux Help: http://www.linuxhelp.org
• Linux Documentation: http://www.linuxdoc.org • Linux software: http://www.rpmfind.net