The Perfect Server - OpenSUSE 11 - Page 3

Want to support HowtoForge? Become a subscriber!
 
Submitted by till (Contact Author) (Forums) on Tue, 2008-07-08 18:59. ::

4 Configure the Network settings

We use Yast, the OpenSuSE system management tool to reconfigure the network card settings. After the first boot, the system is configured to get the IP address with DHCP. For a server we will switch it to a static IP address.

Run

yast2

Select "Network Devices > Network Settings":

Select your network card and then Edit:

Select "Statically assigned IP address" and enter the IP address, subnet mask and hostname and save the changes by selecting "Next":

Now select "Hostname/DNS" and enter the hostname and nameservers:

Now select "Routing" and enter the default gateway and click on "Finish":

Now restart the network:

/etc/init.d/network restart

To configure the firewall, select "Security & Users > Firewall" in Yast.

Then add the following services to the list of allowed services:

Select "Advanced" and enter the TCP ports 80, 81 and 443:

And select "Next" to save the changes.

 

5 Install Some Software

Now we install a few packages that are needed later on. Run

yast2 -i findutils readline libgcc glibc-devel findutils-locate gcc flex lynx compat-readline4 db-devel wget gcc-c++ make vim telnet cron iptables iputils man man-pages

If you're on a 64-bit system (only then!), you must also do this:

cd /usr/lib
ln -s /usr/lib64/libssl.a libssl.a
ln -s /usr/lib64/libssl.so libssl.so

 

6 Quota

To install quota, run

yast2 -i quota

Edit /etc/fstab to look like this (I added ,usrquota,grpquota to the mountpoints / and /srv):

vi /etc/fstab

/dev/disk/by-id/scsi-SATA_VMware_Virtual_00000000000000000001-part1 swap                 swap       defaults              0 0
/dev/disk/by-id/scsi-SATA_VMware_Virtual_00000000000000000001-part2 / ext3 acl,user_xattr,usrquota,grpquota 1 1
/dev/disk/by-id/scsi-SATA_VMware_Virtual_00000000000000000001-part3 /srv ext3 acl,user_xattr,usrquota,grpquota 1 2
proc /proc proc defaults 0 0
sysfs /sys sysfs noauto 0 0
debugfs /sys/kernel/debug debugfs noauto 0 0
usbfs /proc/bus/usb usbfs noauto 0 0
devpts /dev/pts devpts mode=0620,gid=5 0 0

Then run:

touch /aquota.user /aquota.group
chmod 600 /aquota.*
touch /srv/aquota.user /srv/aquota.group
chmod 600 /srv/aquota.*

mount -o remount /
mount -o remount /srv

quotacheck -avugm
quotaon -avug

Dont be worried if you see these error messages

quotacheck: WARNING - Quotafile //aquota.user was probably truncated. Cannot save quota settings...
quotacheck: WARNING - Quotafile //aquota.group was probably truncated. Cannot save quota settings...
quotacheck: Scanning /dev/sda2 [/] done
quotacheck: Checked 5286 directories and 45399 files
quotacheck: WARNING - Quotafile /srv/aquota.user was probably truncated. Cannot save quota settings...
quotacheck: WARNING - Quotafile /srv/aquota.group was probably truncated. Cannot save quota settings...
quotacheck: Scanning /dev/sda3 [/srv] done
quotacheck: Checked 7 directories and 4 files

 

7 DNS Server

Run

yast2 -i bind bind-chrootenv bind-devel bind-utils

Then we add the system startup links for BIND and start it:

chkconfig --add named
/etc/init.d/named start

Bind will run in a chroot jail under /var/lib/named.


Please do not use the comment function to ask for help! If you need help, please use our forum.
Comments will be published after administrator approval.
Submitted by Anonymous (not registered) on Mon, 2009-11-30 03:14.

I'm a nOOb so to run yast2 do the following:

1. type "su" (without quotes duh!)

2. type in your password

3. then type "yast2" (booyah!!!)

Submitted by dmgrant (not registered) on Fri, 2009-05-15 06:32.

The correction Jeff submitted (libdb-devel) did not work for me.  I did notice no installation of "db-devel" on my system so Jeff's statement "db-devel will silently fail to download anything" seems correct.  What I have to offer on my system that sounds like it should fit the bill is called "db43-devel" (Files and Libraries for Berkeley DB Library).

 Just a make a note of it.  I could certainly be wrong.

Submitted by Geoff P (not registered) on Mon, 2009-05-04 01:23.
In Step 5: Install Some Software db-devel should be *libdb-devel* (Berkeley DB development tools). Found via Google search with results subsequently inserted into an RPM search.  db-devel will silently fail to download anything.