<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="http://linux-vserver.at/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://linux-vserver.at/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Roberto.puzzanghera</id>
		<title>Linux-VServer - User contributions [en]</title>
		<link rel="self" type="application/atom+xml" href="http://linux-vserver.at/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Roberto.puzzanghera"/>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Special:Contributions/Roberto.puzzanghera"/>
		<updated>2026-04-10T14:53:07Z</updated>
		<subtitle>User contributions</subtitle>
		<generator>MediaWiki 1.20.2</generator>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2019-07-21T12:59:49Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Contact */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.2 to 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget https://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.2.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 123 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 460M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.2&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.06.08&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.2&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.07.05&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: https://notes.sagredo.eu/other-contents-186/slackware-guest-on-linux-vserver-7.html&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.2 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.sshd and rc.inetd, removing not needed rc scripts&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.sshd $VDIR/$NAME/etc/rc.d/rc.inetd&lt;br /&gt;
rm $VDIR/$NAME/etc/rc.d/rc.cpufreq $VDIR/$NAME/etc/rc.d/rc.modules* $VDIR/$NAME/etc/rc.d/rc.inet1* $VDIR/$NAME/etc/rc.d/rc.loop&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check them later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.2.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.1, 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2016-03-26 17:48:37.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.6	2016-07-09 14:08:48.470713168 +0200&lt;br /&gt;
@@ -37,36 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-# This will also create or update the timestamps in /etc/adjtime.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q &amp;quot; : rtc&amp;quot; /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if [ /etc/adjtime -nt /etc/hardwareclock ]; then&lt;br /&gt;
-    if grep -q &amp;quot;^LOCAL&amp;quot; /etc/adjtime ; then&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    else&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --systohc&lt;br /&gt;
-  elif grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -126,10 +96,6 @@&lt;br /&gt;
   sleep $FUSER_DELAY&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -215,22 +181,11 @@&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $shutdown_command -w&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
 # Stop cgmanager and cgproxy:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.cgmanager ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.cgmanager stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-echo &amp;quot;Unmounting local file systems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot; 2&amp;gt; /dev/null&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only:&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -288,12 +243,3 @@&lt;br /&gt;
     fi&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$shutdown_command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2016-05-05 06:27:00.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M	2016-07-09 14:14:20.090096570 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -109,13 +105,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
@@ -126,14 +115,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.scanluns&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v -e &amp;quot;already mounted&amp;quot; -e &amp;quot;ignored&amp;quot; | cut -f 1 -d : | tr -d ' ' | while read dev ; do mount | grep &amp;quot;${dev} &amp;quot; ; done&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -153,16 +134,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start ACPI daemon.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Enable CPU frequency scaling:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cpufreq ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.cpufreq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons -maxdepth 2 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2016-07-09 14:10:49.388841574 +0200&lt;br /&gt;
@@ -16,51 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
-# and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
-# listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
-# check if things are already running before trying to start them.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (https://notes.sagredo.eu/other-contents-186/slackware-guest-on-linux-vserver-7.html)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2019-07-21T12:59:09Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Make the guest */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.2 to 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget https://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.2.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 123 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 460M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.2&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.06.08&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.2&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.07.05&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: https://notes.sagredo.eu/other-contents-186/slackware-guest-on-linux-vserver-7.html&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.2 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.sshd and rc.inetd, removing not needed rc scripts&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.sshd $VDIR/$NAME/etc/rc.d/rc.inetd&lt;br /&gt;
rm $VDIR/$NAME/etc/rc.d/rc.cpufreq $VDIR/$NAME/etc/rc.d/rc.modules* $VDIR/$NAME/etc/rc.d/rc.inet1* $VDIR/$NAME/etc/rc.d/rc.loop&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check them later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.2.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.1, 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2016-03-26 17:48:37.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.6	2016-07-09 14:08:48.470713168 +0200&lt;br /&gt;
@@ -37,36 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-# This will also create or update the timestamps in /etc/adjtime.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q &amp;quot; : rtc&amp;quot; /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if [ /etc/adjtime -nt /etc/hardwareclock ]; then&lt;br /&gt;
-    if grep -q &amp;quot;^LOCAL&amp;quot; /etc/adjtime ; then&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    else&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --systohc&lt;br /&gt;
-  elif grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -126,10 +96,6 @@&lt;br /&gt;
   sleep $FUSER_DELAY&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -215,22 +181,11 @@&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $shutdown_command -w&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
 # Stop cgmanager and cgproxy:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.cgmanager ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.cgmanager stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-echo &amp;quot;Unmounting local file systems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot; 2&amp;gt; /dev/null&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only:&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -288,12 +243,3 @@&lt;br /&gt;
     fi&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$shutdown_command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2016-05-05 06:27:00.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M	2016-07-09 14:14:20.090096570 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -109,13 +105,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
@@ -126,14 +115,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.scanluns&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v -e &amp;quot;already mounted&amp;quot; -e &amp;quot;ignored&amp;quot; | cut -f 1 -d : | tr -d ' ' | while read dev ; do mount | grep &amp;quot;${dev} &amp;quot; ; done&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -153,16 +134,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start ACPI daemon.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Enable CPU frequency scaling:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cpufreq ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.cpufreq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons -maxdepth 2 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2016-07-09 14:10:49.388841574 +0200&lt;br /&gt;
@@ -16,51 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
-# and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
-# listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
-# check if things are already running before trying to start them.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2019-07-21T12:58:14Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.2 to 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget https://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.2.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 123 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 460M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.2&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.06.08&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.2&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.07.05&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.2 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.sshd and rc.inetd, removing not needed rc scripts&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.sshd $VDIR/$NAME/etc/rc.d/rc.inetd&lt;br /&gt;
rm $VDIR/$NAME/etc/rc.d/rc.cpufreq $VDIR/$NAME/etc/rc.d/rc.modules* $VDIR/$NAME/etc/rc.d/rc.inet1* $VDIR/$NAME/etc/rc.d/rc.loop&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check them later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.2.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.1, 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2016-03-26 17:48:37.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.6	2016-07-09 14:08:48.470713168 +0200&lt;br /&gt;
@@ -37,36 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-# This will also create or update the timestamps in /etc/adjtime.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q &amp;quot; : rtc&amp;quot; /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if [ /etc/adjtime -nt /etc/hardwareclock ]; then&lt;br /&gt;
-    if grep -q &amp;quot;^LOCAL&amp;quot; /etc/adjtime ; then&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    else&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --systohc&lt;br /&gt;
-  elif grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -126,10 +96,6 @@&lt;br /&gt;
   sleep $FUSER_DELAY&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -215,22 +181,11 @@&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $shutdown_command -w&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
 # Stop cgmanager and cgproxy:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.cgmanager ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.cgmanager stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-echo &amp;quot;Unmounting local file systems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot; 2&amp;gt; /dev/null&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only:&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -288,12 +243,3 @@&lt;br /&gt;
     fi&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$shutdown_command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2016-05-05 06:27:00.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M	2016-07-09 14:14:20.090096570 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -109,13 +105,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
@@ -126,14 +115,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.scanluns&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v -e &amp;quot;already mounted&amp;quot; -e &amp;quot;ignored&amp;quot; | cut -f 1 -d : | tr -d ' ' | while read dev ; do mount | grep &amp;quot;${dev} &amp;quot; ; done&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -153,16 +134,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start ACPI daemon.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Enable CPU frequency scaling:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cpufreq ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.cpufreq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons -maxdepth 2 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2016-07-09 14:10:49.388841574 +0200&lt;br /&gt;
@@ -16,51 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
-# and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
-# listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
-# check if things are already running before trying to start them.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2016-07-09T12:26:25Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Patch applayed */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.2 to 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.2.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 123 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 460M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.2&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.06.08&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.2&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.07.05&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.2 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.sshd and rc.inetd, removing not needed rc scripts&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.sshd $VDIR/$NAME/etc/rc.d/rc.inetd&lt;br /&gt;
rm $VDIR/$NAME/etc/rc.d/rc.cpufreq $VDIR/$NAME/etc/rc.d/rc.modules* $VDIR/$NAME/etc/rc.d/rc.inet1* $VDIR/$NAME/etc/rc.d/rc.loop&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check them later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.2.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.1, 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2016-03-26 17:48:37.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.6	2016-07-09 14:08:48.470713168 +0200&lt;br /&gt;
@@ -37,36 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-# This will also create or update the timestamps in /etc/adjtime.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q &amp;quot; : rtc&amp;quot; /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if [ /etc/adjtime -nt /etc/hardwareclock ]; then&lt;br /&gt;
-    if grep -q &amp;quot;^LOCAL&amp;quot; /etc/adjtime ; then&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    else&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --systohc&lt;br /&gt;
-  elif grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -126,10 +96,6 @@&lt;br /&gt;
   sleep $FUSER_DELAY&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -215,22 +181,11 @@&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $shutdown_command -w&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
 # Stop cgmanager and cgproxy:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.cgmanager ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.cgmanager stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-echo &amp;quot;Unmounting local file systems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot; 2&amp;gt; /dev/null&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only:&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -288,12 +243,3 @@&lt;br /&gt;
     fi&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$shutdown_command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2016-05-05 06:27:00.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M	2016-07-09 14:14:20.090096570 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -109,13 +105,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
@@ -126,14 +115,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.scanluns&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v -e &amp;quot;already mounted&amp;quot; -e &amp;quot;ignored&amp;quot; | cut -f 1 -d : | tr -d ' ' | while read dev ; do mount | grep &amp;quot;${dev} &amp;quot; ; done&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -153,16 +134,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start ACPI daemon.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Enable CPU frequency scaling:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cpufreq ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.cpufreq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons -maxdepth 2 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2016-07-09 14:10:49.388841574 +0200&lt;br /&gt;
@@ -16,51 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
-# and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
-# listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
-# check if things are already running before trying to start them.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2016-07-05T12:29:50Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.2 to 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.2.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 123 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 460M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.2&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.06.08&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.2&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.07.05&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.2 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.sshd and rc.inetd, removing not needed rc scripts&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.sshd $VDIR/$NAME/etc/rc.d/rc.inetd&lt;br /&gt;
rm $VDIR/$NAME/etc/rc.d/rc.cpufreq $VDIR/$NAME/etc/rc.d/rc.modules* $VDIR/$NAME/etc/rc.d/rc.inet1* $VDIR/$NAME/etc/rc.d/rc.loop&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check them later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.2.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.1, 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.2 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2016.06.08&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2016-03-26 17:48:37.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.6	2016-06-08 21:57:26.990957045 +0200&lt;br /&gt;
@@ -37,36 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-# This will also create or update the timestamps in /etc/adjtime.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q &amp;quot; : rtc&amp;quot; /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if [ /etc/adjtime -nt /etc/hardwareclock ]; then&lt;br /&gt;
-    if grep -q &amp;quot;^LOCAL&amp;quot; /etc/adjtime ; then&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    else&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --systohc&lt;br /&gt;
-  elif grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -126,10 +96,6 @@&lt;br /&gt;
   sleep $FUSER_DELAY&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -215,22 +181,11 @@&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $shutdown_command -w&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
 # Stop cgmanager and cgproxy:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.cgmanager ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.cgmanager stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-echo &amp;quot;Unmounting local file systems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot; 2&amp;gt; /dev/null&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only:&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -288,12 +243,3 @@&lt;br /&gt;
     fi&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$shutdown_command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2016-05-05 06:27:00.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M	2016-06-08 21:36:45.097439107 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -109,18 +105,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start networking daemons:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
   . /etc/rc.d/rc.scanluns&lt;br /&gt;
@@ -129,11 +113,6 @@&lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
 mount -a -v 2&amp;gt; /dev/null | grep -v -e &amp;quot;already mounted&amp;quot; -e &amp;quot;ignored&amp;quot; | cut -f 1 -d : | tr -d ' ' | while read dev ; do mount | grep &amp;quot;${dev} &amp;quot; ; done&lt;br /&gt;
 &lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -153,16 +132,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start ACPI daemon.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Enable CPU frequency scaling:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cpufreq ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.cpufreq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons -maxdepth 2 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2016-07-05T12:28:33Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Patch applayed */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.2.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 123 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 460M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.2&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.06.08&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.2&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.07.05&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.2 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.sshd and rc.inetd, removing not needed rc scripts&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.sshd $VDIR/$NAME/etc/rc.d/rc.inetd&lt;br /&gt;
rm $VDIR/$NAME/etc/rc.d/rc.cpufreq $VDIR/$NAME/etc/rc.d/rc.modules* $VDIR/$NAME/etc/rc.d/rc.inet1* $VDIR/$NAME/etc/rc.d/rc.loop&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check them later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.2.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.1, 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.2 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2016.06.08&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2016-03-26 17:48:37.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.6	2016-06-08 21:57:26.990957045 +0200&lt;br /&gt;
@@ -37,36 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-# This will also create or update the timestamps in /etc/adjtime.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q &amp;quot; : rtc&amp;quot; /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if [ /etc/adjtime -nt /etc/hardwareclock ]; then&lt;br /&gt;
-    if grep -q &amp;quot;^LOCAL&amp;quot; /etc/adjtime ; then&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    else&lt;br /&gt;
-      echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --systohc&lt;br /&gt;
-  elif grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    if [ ! -r /etc/adjtime ]; then&lt;br /&gt;
-      echo &amp;quot;Creating system time correction file /etc/adjtime.&amp;quot;&lt;br /&gt;
-    fi&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -126,10 +96,6 @@&lt;br /&gt;
   sleep $FUSER_DELAY&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -215,22 +181,11 @@&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $shutdown_command -w&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
 # Stop cgmanager and cgproxy:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.cgmanager ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.cgmanager stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-echo &amp;quot;Unmounting local file systems:&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs | tr -d ' ' | grep successfully | sed &amp;quot;s/:successfullyunmounted/ has been successfully unmounted./g&amp;quot; 2&amp;gt; /dev/null&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only:&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -288,12 +243,3 @@&lt;br /&gt;
     fi&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$shutdown_command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2016-05-05 06:27:00.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M	2016-06-08 21:36:45.097439107 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -109,18 +105,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start networking daemons:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
   . /etc/rc.d/rc.scanluns&lt;br /&gt;
@@ -129,11 +113,6 @@&lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
 mount -a -v 2&amp;gt; /dev/null | grep -v -e &amp;quot;already mounted&amp;quot; -e &amp;quot;ignored&amp;quot; | cut -f 1 -d : | tr -d ' ' | while read dev ; do mount | grep &amp;quot;${dev} &amp;quot; ; done&lt;br /&gt;
 &lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -153,16 +132,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start ACPI daemon.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Enable CPU frequency scaling:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cpufreq ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.cpufreq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons -maxdepth 2 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2016-07-05T12:26:41Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Apply the patch */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.2.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 123 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 460M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.2&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.06.08&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.2&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.07.05&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.2 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.sshd and rc.inetd, removing not needed rc scripts&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.sshd $VDIR/$NAME/etc/rc.d/rc.inetd&lt;br /&gt;
rm $VDIR/$NAME/etc/rc.d/rc.cpufreq $VDIR/$NAME/etc/rc.d/rc.modules* $VDIR/$NAME/etc/rc.d/rc.inet1* $VDIR/$NAME/etc/rc.d/rc.loop&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check them later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.2.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.1, 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2016-07-05T12:25:42Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Make the guest */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.2.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 123 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 460M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.2&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.06.08&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.2&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.07.05&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.2 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.sshd and rc.inetd, removing not needed rc scripts&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.sshd $VDIR/$NAME/etc/rc.d/rc.inetd&lt;br /&gt;
rm $VDIR/$NAME/etc/rc.d/rc.cpufreq $VDIR/$NAME/etc/rc.d/rc.modules* $VDIR/$NAME/etc/rc.d/rc.inet1* $VDIR/$NAME/etc/rc.d/rc.loop&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check them later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.1.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2016-07-05T12:24:43Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.2.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 123 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 460M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.2&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2016.06.08&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.2&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
    if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
              echo&lt;br /&gt;
        echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info at http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.1.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2016-07-05T12:23:23Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.2.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
    mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
    do&lt;br /&gt;
        IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
        PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                    wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
    if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
              echo&lt;br /&gt;
        echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info at http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.1.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2014-08-05T18:31:47Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Patch applayed */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
    mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
    do&lt;br /&gt;
        IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
        PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                    wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
    if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
              echo&lt;br /&gt;
        echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info at http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.1.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Documentation</id>
		<title>Documentation</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Documentation"/>
				<updated>2014-01-05T18:49:16Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Installation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;margin: 2em auto 2em auto; padding: 10px; background-color: #F9ECCD; border: 1px solid #004433; text-align: center;&amp;quot;&amp;gt;&lt;br /&gt;
[[Image:Icon-Caution.png|left]]&lt;br /&gt;
We are currently migrating to MediaWiki from our old system, but not all content has been migrated yet. Take a look at the [[Wiki Team]] page for instructions how to help or look at the [http://oldwiki.linux-vserver.org old wiki] to find the information not migrated yet.&lt;br /&gt;
&lt;br /&gt;
'''To ease migration we created a [[List of old Documentation pages]].'''&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
* [[Overview|Virtualization Overview]]&lt;br /&gt;
* [[Usage Scenarios]]&lt;br /&gt;
* [[Feature Matrix]]&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
* [[Installation Considerations]]&lt;br /&gt;
* [[Installation on Linux 2.6]]: from source, both the kernel and util-vserver&lt;br /&gt;
* [[Installation on ArchLinux]]&lt;br /&gt;
* [[Installation on CentOS]]&lt;br /&gt;
* [[Installation on Debian]]&lt;br /&gt;
* [[Installation on Fedora]]&lt;br /&gt;
* [[Installation on Gentoo]]&lt;br /&gt;
* [[Installation on Mandrake]]&lt;br /&gt;
* [http://www.pld-linux.org/Docs/Vserver Installation on PLD-Linux]&lt;br /&gt;
* [[Installation on Redhat]]&lt;br /&gt;
* [[Installation on Slackware]]&lt;br /&gt;
* [[Installation on Slackware 14]]&lt;br /&gt;
* [[Installation on SuSE/OpenSUSE]]&lt;br /&gt;
* [[Installation on Ubuntu]]&lt;br /&gt;
&lt;br /&gt;
== Configuration ==&lt;br /&gt;
&lt;br /&gt;
* [[Util-vserver:Documentation|util-vserver Documentation]]&lt;br /&gt;
* [[vcd:Documentation|VServer Control Daemon Documentation]]&lt;br /&gt;
* [[Share a directory among multiple guests]]&lt;br /&gt;
* [[Standard_non-shared_quota]]&lt;br /&gt;
&lt;br /&gt;
== Guides and Howtos ==&lt;br /&gt;
&lt;br /&gt;
* [[Building Guest Systems]]&lt;br /&gt;
* [[util-vserver:Howto virtualize an exisiting Linux server|Howto virtualize an existing Linux server]]&lt;br /&gt;
* [[VCMD HowTo]]&lt;br /&gt;
* [[Howto make bsd-style init sysv-compatible|Howto make Bsd-style init sysv-compatible (archlinux guest system)]]&lt;br /&gt;
* [[Installing 32-bit Fedora on 64-bit Debian]]&lt;br /&gt;
* [[Installing Ubuntu on Debian]]&lt;br /&gt;
* [[Installing an openSUSE vserver guest]]&lt;br /&gt;
* [[Networking vserver guests]]&lt;br /&gt;
* [[Howto HostAuth]]&lt;br /&gt;
* [[Fuse_GlusterFS| Fuse and GlusterFS]]&lt;br /&gt;
* [[yum-patch|How to patch vyum]]&lt;br /&gt;
* [[yum-upgrade-3.2.4|Upgrading existing installations to yum-3.2.4]]&lt;br /&gt;
* [[Migrating from OpenVZ to Linux-Vserver]]&lt;br /&gt;
* [[Getting_high_with_lenny]]&lt;br /&gt;
* [[Installing_Ubuntu_8.04_Hardy_as_guest]]&lt;br /&gt;
* [[Applying CPU Limits]]&lt;br /&gt;
* [[Upgrading from Etch to Lenny]]&lt;br /&gt;
* [[Upstart issues]]&lt;br /&gt;
* [[Limit Networking on Multihomed hosts]]&lt;br /&gt;
* [[Read-only_RootFS]]&lt;br /&gt;
* [[Building_CentOS_6_Guest]]&lt;br /&gt;
* [[Building_CentOS_6_ALT_Guest]]&lt;br /&gt;
&lt;br /&gt;
== Lists &amp;amp;amp; Theory ==&lt;br /&gt;
&lt;br /&gt;
* Basic configuration&lt;br /&gt;
** [[Capabilities and Flags]]&lt;br /&gt;
** [[CPU Scheduler]]&lt;br /&gt;
** [[Disk Limits and Quota]]&lt;br /&gt;
** [[Resource Limits]]&lt;br /&gt;
*** [[Memory Limits]]&lt;br /&gt;
*** [[Network Bandwidth Management]]&lt;br /&gt;
** [[Virtual System Information]]&lt;br /&gt;
** [[Unification]]&lt;br /&gt;
&lt;br /&gt;
* Security Considerations&lt;br /&gt;
** [[Secure Capabilities]]&lt;br /&gt;
** [[Secure chroot Barrier]]&lt;br /&gt;
** [[Secure Device Nodes]]&lt;br /&gt;
** [[Secure ProcFS Entries]]&lt;br /&gt;
&lt;br /&gt;
* Performance and Stability&lt;br /&gt;
** [[Virtualization Overhead]]&lt;br /&gt;
&lt;br /&gt;
* Implementation Details&lt;br /&gt;
** [[Context Accounting]]&lt;br /&gt;
** [[Filesystem Attributes]]&lt;br /&gt;
** [[Filesystem Tagging]]&lt;br /&gt;
** [[Filesystem Namespaces]]&lt;br /&gt;
** [[Kernel Userspace Helper]]&lt;br /&gt;
** [[Mainline Kernel Virtualization]]&lt;br /&gt;
** [[ProcFS]]&lt;br /&gt;
** [[Syscall Command Switch]]&lt;br /&gt;
&lt;br /&gt;
== External Resources ==&lt;br /&gt;
&lt;br /&gt;
* [http://vserver.13thfloor.at/Remote-Reset/ Simple Remote reset] (remote reset/power your vserver box)&lt;br /&gt;
* [http://vserver.13thfloor.at/Null-Modem/ NullModem cables] [http://www.loop-back.com/null-mod.html II] [http://www.tldp.org/HOWTO/Remote-Serial-Console-HOWTO/serial-pc-terminal.html III] (cable required for serial console)&lt;br /&gt;
* [http://www.tldp.org/HOWTO/Remote-Serial-Console-HOWTO/index.html Serial Console HOWTO]&lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation| ]]&lt;br /&gt;
[[Category:Community]]&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Documentation</id>
		<title>Documentation</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Documentation"/>
				<updated>2014-01-05T18:47:50Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Installation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;margin: 2em auto 2em auto; padding: 10px; background-color: #F9ECCD; border: 1px solid #004433; text-align: center;&amp;quot;&amp;gt;&lt;br /&gt;
[[Image:Icon-Caution.png|left]]&lt;br /&gt;
We are currently migrating to MediaWiki from our old system, but not all content has been migrated yet. Take a look at the [[Wiki Team]] page for instructions how to help or look at the [http://oldwiki.linux-vserver.org old wiki] to find the information not migrated yet.&lt;br /&gt;
&lt;br /&gt;
'''To ease migration we created a [[List of old Documentation pages]].'''&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
* [[Overview|Virtualization Overview]]&lt;br /&gt;
* [[Usage Scenarios]]&lt;br /&gt;
* [[Feature Matrix]]&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
* [[Installation Considerations]]&lt;br /&gt;
* [[Installation on Linux 2.6]]: from source, both the kernel and util-vserver&lt;br /&gt;
* [[Installation on ArchLinux]]&lt;br /&gt;
* [[Installation on CentOS]]&lt;br /&gt;
* [[Installation on Debian]]&lt;br /&gt;
* [[Installation on Fedora]]&lt;br /&gt;
* [[Installation on Gentoo]]&lt;br /&gt;
* [[Installation on Mandrake]]&lt;br /&gt;
* [http://www.pld-linux.org/Docs/Vserver Installation on PLD-Linux]&lt;br /&gt;
* [[Installation on Redhat]]&lt;br /&gt;
* [[Installation on Slackware]]&lt;br /&gt;
* [[Installation on Slackware 14.1]]&lt;br /&gt;
* [[Installation on SuSE/OpenSUSE]]&lt;br /&gt;
* [[Installation on Ubuntu]]&lt;br /&gt;
&lt;br /&gt;
== Configuration ==&lt;br /&gt;
&lt;br /&gt;
* [[Util-vserver:Documentation|util-vserver Documentation]]&lt;br /&gt;
* [[vcd:Documentation|VServer Control Daemon Documentation]]&lt;br /&gt;
* [[Share a directory among multiple guests]]&lt;br /&gt;
* [[Standard_non-shared_quota]]&lt;br /&gt;
&lt;br /&gt;
== Guides and Howtos ==&lt;br /&gt;
&lt;br /&gt;
* [[Building Guest Systems]]&lt;br /&gt;
* [[util-vserver:Howto virtualize an exisiting Linux server|Howto virtualize an existing Linux server]]&lt;br /&gt;
* [[VCMD HowTo]]&lt;br /&gt;
* [[Howto make bsd-style init sysv-compatible|Howto make Bsd-style init sysv-compatible (archlinux guest system)]]&lt;br /&gt;
* [[Installing 32-bit Fedora on 64-bit Debian]]&lt;br /&gt;
* [[Installing Ubuntu on Debian]]&lt;br /&gt;
* [[Installing an openSUSE vserver guest]]&lt;br /&gt;
* [[Networking vserver guests]]&lt;br /&gt;
* [[Howto HostAuth]]&lt;br /&gt;
* [[Fuse_GlusterFS| Fuse and GlusterFS]]&lt;br /&gt;
* [[yum-patch|How to patch vyum]]&lt;br /&gt;
* [[yum-upgrade-3.2.4|Upgrading existing installations to yum-3.2.4]]&lt;br /&gt;
* [[Migrating from OpenVZ to Linux-Vserver]]&lt;br /&gt;
* [[Getting_high_with_lenny]]&lt;br /&gt;
* [[Installing_Ubuntu_8.04_Hardy_as_guest]]&lt;br /&gt;
* [[Applying CPU Limits]]&lt;br /&gt;
* [[Upgrading from Etch to Lenny]]&lt;br /&gt;
* [[Upstart issues]]&lt;br /&gt;
* [[Limit Networking on Multihomed hosts]]&lt;br /&gt;
* [[Read-only_RootFS]]&lt;br /&gt;
* [[Building_CentOS_6_Guest]]&lt;br /&gt;
* [[Building_CentOS_6_ALT_Guest]]&lt;br /&gt;
&lt;br /&gt;
== Lists &amp;amp;amp; Theory ==&lt;br /&gt;
&lt;br /&gt;
* Basic configuration&lt;br /&gt;
** [[Capabilities and Flags]]&lt;br /&gt;
** [[CPU Scheduler]]&lt;br /&gt;
** [[Disk Limits and Quota]]&lt;br /&gt;
** [[Resource Limits]]&lt;br /&gt;
*** [[Memory Limits]]&lt;br /&gt;
*** [[Network Bandwidth Management]]&lt;br /&gt;
** [[Virtual System Information]]&lt;br /&gt;
** [[Unification]]&lt;br /&gt;
&lt;br /&gt;
* Security Considerations&lt;br /&gt;
** [[Secure Capabilities]]&lt;br /&gt;
** [[Secure chroot Barrier]]&lt;br /&gt;
** [[Secure Device Nodes]]&lt;br /&gt;
** [[Secure ProcFS Entries]]&lt;br /&gt;
&lt;br /&gt;
* Performance and Stability&lt;br /&gt;
** [[Virtualization Overhead]]&lt;br /&gt;
&lt;br /&gt;
* Implementation Details&lt;br /&gt;
** [[Context Accounting]]&lt;br /&gt;
** [[Filesystem Attributes]]&lt;br /&gt;
** [[Filesystem Tagging]]&lt;br /&gt;
** [[Filesystem Namespaces]]&lt;br /&gt;
** [[Kernel Userspace Helper]]&lt;br /&gt;
** [[Mainline Kernel Virtualization]]&lt;br /&gt;
** [[ProcFS]]&lt;br /&gt;
** [[Syscall Command Switch]]&lt;br /&gt;
&lt;br /&gt;
== External Resources ==&lt;br /&gt;
&lt;br /&gt;
* [http://vserver.13thfloor.at/Remote-Reset/ Simple Remote reset] (remote reset/power your vserver box)&lt;br /&gt;
* [http://vserver.13thfloor.at/Null-Modem/ NullModem cables] [http://www.loop-back.com/null-mod.html II] [http://www.tldp.org/HOWTO/Remote-Serial-Console-HOWTO/serial-pc-terminal.html III] (cable required for serial console)&lt;br /&gt;
* [http://www.tldp.org/HOWTO/Remote-Serial-Console-HOWTO/index.html Serial Console HOWTO]&lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation| ]]&lt;br /&gt;
[[Category:Community]]&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2014-01-05T18:28:40Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Make the guest */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
    mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
    do&lt;br /&gt;
        IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
        PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                    wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
    if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
              echo&lt;br /&gt;
        echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info at http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.1.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.0.rej rc.d/rc.0.rej&lt;br /&gt;
--- rc.d-original/rc.0.rej	1970-01-01 01:00:00.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.0.rej	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -0,0 +1,194 @@&lt;br /&gt;
+--- rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
++++ rc.0	2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
+@@ -37,22 +37,6 @@&lt;br /&gt;
+ 		;;&lt;br /&gt;
+ esac&lt;br /&gt;
+ &lt;br /&gt;
+-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
+-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
+-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
+-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
+-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
+-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
+-  fi&lt;br /&gt;
+-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
+-  else&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Run any local shutdown scripts:&lt;br /&gt;
+ if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
+   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
+@@ -98,24 +82,6 @@&lt;br /&gt;
+   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
+-# unmounting NFS volumes:&lt;br /&gt;
+-unset FUSER_DELAY&lt;br /&gt;
+-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
+-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
+-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
+-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
+-  FUSER_DELAY=5&lt;br /&gt;
+-done&lt;br /&gt;
+-# If fuser was run, let it have some delay:&lt;br /&gt;
+-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
+-  sleep $FUSER_DELAY&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
+-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
+-&lt;br /&gt;
+ # Try to shut down pppd:&lt;br /&gt;
+ PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
+ if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
+@@ -131,45 +97,11 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Bring down the networking system, but first make sure that this&lt;br /&gt;
+-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
+-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
+-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
+-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
+-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
+-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
+-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
+-  # restore themselves.&lt;br /&gt;
+-  sleep 2&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Shut down PCMCIA devices:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
+-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
+-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
+-  /bin/sleep 5&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Turn off process accounting:&lt;br /&gt;
+ if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
+   /sbin/accton off&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Terminate acpid before syslog:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
+-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Stop udev:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
+-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Kill all remaining processes.&lt;br /&gt;
+ if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
+   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
+@@ -187,16 +119,6 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Carry a random seed between reboots.&lt;br /&gt;
+-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
+-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
+-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
+-else&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
+-fi&lt;br /&gt;
+-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
+-&lt;br /&gt;
+ # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
+ $command -w&lt;br /&gt;
+ &lt;br /&gt;
+@@ -205,80 +127,5 @@&lt;br /&gt;
+   rm -f /var/lock/subsys/*&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Turn off swap:&lt;br /&gt;
+-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
+-/sbin/swapoff -a&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
+-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
+-&lt;br /&gt;
+ # This never hurts:&lt;br /&gt;
+ /bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# Close any volumes opened by cryptsetup:&lt;br /&gt;
+-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
+-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
+-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
+-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
+-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
+-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
+-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
+-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
+-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
+-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
+-      # then run mkswap on the underlying device -&lt;br /&gt;
+-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
+-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
+-      mkswap $DEV&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  done&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Deactivate LVM volume groups:&lt;br /&gt;
+-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
+-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
+-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
+-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
+-# remounted as read-only first)&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
+-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
+-/bin/sleep 3&lt;br /&gt;
+-&lt;br /&gt;
+-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
+-wait&lt;br /&gt;
+-&lt;br /&gt;
+-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
+-  # See if this is a powerfail situation:&lt;br /&gt;
+-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    # Signal UPS to shut off the inverter:&lt;br /&gt;
+-    /sbin/genpowerd -k&lt;br /&gt;
+-    if [ ! $? = 0 ]; then&lt;br /&gt;
+-      echo&lt;br /&gt;
+-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
+-      # Wasting 15 seconds of precious power:&lt;br /&gt;
+-      /bin/sleep 15&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
+-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
+-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
+-  /sbin/reboot&lt;br /&gt;
+-else&lt;br /&gt;
+-  /sbin/poweroff&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2014-01-05T18:24:59Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Contact */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
    mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
    do&lt;br /&gt;
        IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
        PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                    wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
    if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
              echo&lt;br /&gt;
        echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.1.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.0.rej rc.d/rc.0.rej&lt;br /&gt;
--- rc.d-original/rc.0.rej	1970-01-01 01:00:00.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.0.rej	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -0,0 +1,194 @@&lt;br /&gt;
+--- rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
++++ rc.0	2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
+@@ -37,22 +37,6 @@&lt;br /&gt;
+ 		;;&lt;br /&gt;
+ esac&lt;br /&gt;
+ &lt;br /&gt;
+-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
+-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
+-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
+-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
+-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
+-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
+-  fi&lt;br /&gt;
+-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
+-  else&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Run any local shutdown scripts:&lt;br /&gt;
+ if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
+   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
+@@ -98,24 +82,6 @@&lt;br /&gt;
+   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
+-# unmounting NFS volumes:&lt;br /&gt;
+-unset FUSER_DELAY&lt;br /&gt;
+-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
+-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
+-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
+-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
+-  FUSER_DELAY=5&lt;br /&gt;
+-done&lt;br /&gt;
+-# If fuser was run, let it have some delay:&lt;br /&gt;
+-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
+-  sleep $FUSER_DELAY&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
+-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
+-&lt;br /&gt;
+ # Try to shut down pppd:&lt;br /&gt;
+ PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
+ if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
+@@ -131,45 +97,11 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Bring down the networking system, but first make sure that this&lt;br /&gt;
+-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
+-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
+-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
+-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
+-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
+-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
+-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
+-  # restore themselves.&lt;br /&gt;
+-  sleep 2&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Shut down PCMCIA devices:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
+-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
+-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
+-  /bin/sleep 5&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Turn off process accounting:&lt;br /&gt;
+ if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
+   /sbin/accton off&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Terminate acpid before syslog:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
+-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Stop udev:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
+-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Kill all remaining processes.&lt;br /&gt;
+ if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
+   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
+@@ -187,16 +119,6 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Carry a random seed between reboots.&lt;br /&gt;
+-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
+-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
+-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
+-else&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
+-fi&lt;br /&gt;
+-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
+-&lt;br /&gt;
+ # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
+ $command -w&lt;br /&gt;
+ &lt;br /&gt;
+@@ -205,80 +127,5 @@&lt;br /&gt;
+   rm -f /var/lock/subsys/*&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Turn off swap:&lt;br /&gt;
+-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
+-/sbin/swapoff -a&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
+-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
+-&lt;br /&gt;
+ # This never hurts:&lt;br /&gt;
+ /bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# Close any volumes opened by cryptsetup:&lt;br /&gt;
+-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
+-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
+-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
+-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
+-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
+-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
+-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
+-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
+-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
+-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
+-      # then run mkswap on the underlying device -&lt;br /&gt;
+-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
+-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
+-      mkswap $DEV&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  done&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Deactivate LVM volume groups:&lt;br /&gt;
+-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
+-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
+-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
+-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
+-# remounted as read-only first)&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
+-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
+-/bin/sleep 3&lt;br /&gt;
+-&lt;br /&gt;
+-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
+-wait&lt;br /&gt;
+-&lt;br /&gt;
+-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
+-  # See if this is a powerfail situation:&lt;br /&gt;
+-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    # Signal UPS to shut off the inverter:&lt;br /&gt;
+-    /sbin/genpowerd -k&lt;br /&gt;
+-    if [ ! $? = 0 ]; then&lt;br /&gt;
+-      echo&lt;br /&gt;
+-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
+-      # Wasting 15 seconds of precious power:&lt;br /&gt;
+-      /bin/sleep 15&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
+-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
+-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
+-  /sbin/reboot&lt;br /&gt;
+-else&lt;br /&gt;
+-  /sbin/poweroff&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://notes.sagredo.eu/node/7)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2014-01-05T18:23:43Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Apply the patch */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
    mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
    do&lt;br /&gt;
        IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
        PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                    wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
    if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
              echo&lt;br /&gt;
        echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.1.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 14.0, 13.37 and 13.1, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.0.rej rc.d/rc.0.rej&lt;br /&gt;
--- rc.d-original/rc.0.rej	1970-01-01 01:00:00.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.0.rej	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -0,0 +1,194 @@&lt;br /&gt;
+--- rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
++++ rc.0	2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
+@@ -37,22 +37,6 @@&lt;br /&gt;
+ 		;;&lt;br /&gt;
+ esac&lt;br /&gt;
+ &lt;br /&gt;
+-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
+-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
+-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
+-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
+-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
+-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
+-  fi&lt;br /&gt;
+-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
+-  else&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Run any local shutdown scripts:&lt;br /&gt;
+ if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
+   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
+@@ -98,24 +82,6 @@&lt;br /&gt;
+   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
+-# unmounting NFS volumes:&lt;br /&gt;
+-unset FUSER_DELAY&lt;br /&gt;
+-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
+-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
+-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
+-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
+-  FUSER_DELAY=5&lt;br /&gt;
+-done&lt;br /&gt;
+-# If fuser was run, let it have some delay:&lt;br /&gt;
+-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
+-  sleep $FUSER_DELAY&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
+-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
+-&lt;br /&gt;
+ # Try to shut down pppd:&lt;br /&gt;
+ PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
+ if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
+@@ -131,45 +97,11 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Bring down the networking system, but first make sure that this&lt;br /&gt;
+-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
+-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
+-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
+-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
+-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
+-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
+-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
+-  # restore themselves.&lt;br /&gt;
+-  sleep 2&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Shut down PCMCIA devices:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
+-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
+-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
+-  /bin/sleep 5&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Turn off process accounting:&lt;br /&gt;
+ if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
+   /sbin/accton off&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Terminate acpid before syslog:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
+-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Stop udev:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
+-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Kill all remaining processes.&lt;br /&gt;
+ if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
+   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
+@@ -187,16 +119,6 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Carry a random seed between reboots.&lt;br /&gt;
+-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
+-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
+-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
+-else&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
+-fi&lt;br /&gt;
+-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
+-&lt;br /&gt;
+ # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
+ $command -w&lt;br /&gt;
+ &lt;br /&gt;
+@@ -205,80 +127,5 @@&lt;br /&gt;
+   rm -f /var/lock/subsys/*&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Turn off swap:&lt;br /&gt;
+-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
+-/sbin/swapoff -a&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
+-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
+-&lt;br /&gt;
+ # This never hurts:&lt;br /&gt;
+ /bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# Close any volumes opened by cryptsetup:&lt;br /&gt;
+-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
+-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
+-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
+-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
+-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
+-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
+-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
+-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
+-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
+-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
+-      # then run mkswap on the underlying device -&lt;br /&gt;
+-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
+-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
+-      mkswap $DEV&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  done&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Deactivate LVM volume groups:&lt;br /&gt;
+-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
+-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
+-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
+-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
+-# remounted as read-only first)&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
+-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
+-/bin/sleep 3&lt;br /&gt;
+-&lt;br /&gt;
+-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
+-wait&lt;br /&gt;
+-&lt;br /&gt;
+-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
+-  # See if this is a powerfail situation:&lt;br /&gt;
+-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    # Signal UPS to shut off the inverter:&lt;br /&gt;
+-    /sbin/genpowerd -k&lt;br /&gt;
+-    if [ ! $? = 0 ]; then&lt;br /&gt;
+-      echo&lt;br /&gt;
+-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
+-      # Wasting 15 seconds of precious power:&lt;br /&gt;
+-      /bin/sleep 15&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
+-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
+-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
+-  /sbin/reboot&lt;br /&gt;
+-else&lt;br /&gt;
+-  /sbin/poweroff&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2014-01-05T18:23:10Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Apply the patch */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
    mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
    do&lt;br /&gt;
        IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
        PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                    wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
    if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
              echo&lt;br /&gt;
        echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.1.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.0.rej rc.d/rc.0.rej&lt;br /&gt;
--- rc.d-original/rc.0.rej	1970-01-01 01:00:00.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.0.rej	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -0,0 +1,194 @@&lt;br /&gt;
+--- rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
++++ rc.0	2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
+@@ -37,22 +37,6 @@&lt;br /&gt;
+ 		;;&lt;br /&gt;
+ esac&lt;br /&gt;
+ &lt;br /&gt;
+-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
+-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
+-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
+-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
+-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
+-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
+-  fi&lt;br /&gt;
+-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
+-  else&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Run any local shutdown scripts:&lt;br /&gt;
+ if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
+   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
+@@ -98,24 +82,6 @@&lt;br /&gt;
+   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
+-# unmounting NFS volumes:&lt;br /&gt;
+-unset FUSER_DELAY&lt;br /&gt;
+-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
+-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
+-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
+-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
+-  FUSER_DELAY=5&lt;br /&gt;
+-done&lt;br /&gt;
+-# If fuser was run, let it have some delay:&lt;br /&gt;
+-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
+-  sleep $FUSER_DELAY&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
+-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
+-&lt;br /&gt;
+ # Try to shut down pppd:&lt;br /&gt;
+ PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
+ if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
+@@ -131,45 +97,11 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Bring down the networking system, but first make sure that this&lt;br /&gt;
+-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
+-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
+-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
+-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
+-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
+-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
+-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
+-  # restore themselves.&lt;br /&gt;
+-  sleep 2&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Shut down PCMCIA devices:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
+-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
+-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
+-  /bin/sleep 5&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Turn off process accounting:&lt;br /&gt;
+ if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
+   /sbin/accton off&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Terminate acpid before syslog:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
+-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Stop udev:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
+-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Kill all remaining processes.&lt;br /&gt;
+ if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
+   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
+@@ -187,16 +119,6 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Carry a random seed between reboots.&lt;br /&gt;
+-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
+-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
+-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
+-else&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
+-fi&lt;br /&gt;
+-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
+-&lt;br /&gt;
+ # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
+ $command -w&lt;br /&gt;
+ &lt;br /&gt;
+@@ -205,80 +127,5 @@&lt;br /&gt;
+   rm -f /var/lock/subsys/*&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Turn off swap:&lt;br /&gt;
+-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
+-/sbin/swapoff -a&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
+-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
+-&lt;br /&gt;
+ # This never hurts:&lt;br /&gt;
+ /bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# Close any volumes opened by cryptsetup:&lt;br /&gt;
+-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
+-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
+-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
+-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
+-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
+-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
+-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
+-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
+-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
+-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
+-      # then run mkswap on the underlying device -&lt;br /&gt;
+-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
+-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
+-      mkswap $DEV&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  done&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Deactivate LVM volume groups:&lt;br /&gt;
+-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
+-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
+-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
+-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
+-# remounted as read-only first)&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
+-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
+-/bin/sleep 3&lt;br /&gt;
+-&lt;br /&gt;
+-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
+-wait&lt;br /&gt;
+-&lt;br /&gt;
+-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
+-  # See if this is a powerfail situation:&lt;br /&gt;
+-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    # Signal UPS to shut off the inverter:&lt;br /&gt;
+-    /sbin/genpowerd -k&lt;br /&gt;
+-    if [ ! $? = 0 ]; then&lt;br /&gt;
+-      echo&lt;br /&gt;
+-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
+-      # Wasting 15 seconds of precious power:&lt;br /&gt;
+-      /bin/sleep 15&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
+-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
+-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
+-  /sbin/reboot&lt;br /&gt;
+-else&lt;br /&gt;
+-  /sbin/poweroff&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2014-01-05T18:22:15Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
    mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
    do&lt;br /&gt;
        IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
        PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                    wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
    if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
              echo&lt;br /&gt;
        echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.0.rej rc.d/rc.0.rej&lt;br /&gt;
--- rc.d-original/rc.0.rej	1970-01-01 01:00:00.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.0.rej	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -0,0 +1,194 @@&lt;br /&gt;
+--- rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
++++ rc.0	2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
+@@ -37,22 +37,6 @@&lt;br /&gt;
+ 		;;&lt;br /&gt;
+ esac&lt;br /&gt;
+ &lt;br /&gt;
+-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
+-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
+-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
+-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
+-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
+-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
+-  fi&lt;br /&gt;
+-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
+-  else&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Run any local shutdown scripts:&lt;br /&gt;
+ if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
+   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
+@@ -98,24 +82,6 @@&lt;br /&gt;
+   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
+-# unmounting NFS volumes:&lt;br /&gt;
+-unset FUSER_DELAY&lt;br /&gt;
+-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
+-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
+-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
+-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
+-  FUSER_DELAY=5&lt;br /&gt;
+-done&lt;br /&gt;
+-# If fuser was run, let it have some delay:&lt;br /&gt;
+-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
+-  sleep $FUSER_DELAY&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
+-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
+-&lt;br /&gt;
+ # Try to shut down pppd:&lt;br /&gt;
+ PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
+ if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
+@@ -131,45 +97,11 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Bring down the networking system, but first make sure that this&lt;br /&gt;
+-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
+-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
+-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
+-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
+-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
+-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
+-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
+-  # restore themselves.&lt;br /&gt;
+-  sleep 2&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Shut down PCMCIA devices:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
+-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
+-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
+-  /bin/sleep 5&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Turn off process accounting:&lt;br /&gt;
+ if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
+   /sbin/accton off&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Terminate acpid before syslog:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
+-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Stop udev:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
+-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Kill all remaining processes.&lt;br /&gt;
+ if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
+   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
+@@ -187,16 +119,6 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Carry a random seed between reboots.&lt;br /&gt;
+-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
+-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
+-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
+-else&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
+-fi&lt;br /&gt;
+-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
+-&lt;br /&gt;
+ # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
+ $command -w&lt;br /&gt;
+ &lt;br /&gt;
+@@ -205,80 +127,5 @@&lt;br /&gt;
+   rm -f /var/lock/subsys/*&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Turn off swap:&lt;br /&gt;
+-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
+-/sbin/swapoff -a&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
+-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
+-&lt;br /&gt;
+ # This never hurts:&lt;br /&gt;
+ /bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# Close any volumes opened by cryptsetup:&lt;br /&gt;
+-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
+-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
+-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
+-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
+-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
+-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
+-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
+-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
+-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
+-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
+-      # then run mkswap on the underlying device -&lt;br /&gt;
+-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
+-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
+-      mkswap $DEV&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  done&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Deactivate LVM volume groups:&lt;br /&gt;
+-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
+-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
+-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
+-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
+-# remounted as read-only first)&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
+-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
+-/bin/sleep 3&lt;br /&gt;
+-&lt;br /&gt;
+-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
+-wait&lt;br /&gt;
+-&lt;br /&gt;
+-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
+-  # See if this is a powerfail situation:&lt;br /&gt;
+-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    # Signal UPS to shut off the inverter:&lt;br /&gt;
+-    /sbin/genpowerd -k&lt;br /&gt;
+-    if [ ! $? = 0 ]; then&lt;br /&gt;
+-      echo&lt;br /&gt;
+-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
+-      # Wasting 15 seconds of precious power:&lt;br /&gt;
+-      /bin/sleep 15&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
+-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
+-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
+-  /sbin/reboot&lt;br /&gt;
+-else&lt;br /&gt;
+-  /sbin/poweroff&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2013-12-29T13:34:02Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Patch applayed */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1** (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
    mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
    do&lt;br /&gt;
        IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
        PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                    wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
    if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
              echo&lt;br /&gt;
        echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.12.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.0.rej rc.d/rc.0.rej&lt;br /&gt;
--- rc.d-original/rc.0.rej	1970-01-01 01:00:00.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.0.rej	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -0,0 +1,194 @@&lt;br /&gt;
+--- rc.0	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
++++ rc.0	2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
+@@ -37,22 +37,6 @@&lt;br /&gt;
+ 		;;&lt;br /&gt;
+ esac&lt;br /&gt;
+ &lt;br /&gt;
+-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
+-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
+-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
+-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
+-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
+-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
+-  fi&lt;br /&gt;
+-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
+-  else&lt;br /&gt;
+-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
+-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Run any local shutdown scripts:&lt;br /&gt;
+ if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
+   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
+@@ -98,24 +82,6 @@&lt;br /&gt;
+   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
+-# unmounting NFS volumes:&lt;br /&gt;
+-unset FUSER_DELAY&lt;br /&gt;
+-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
+-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
+-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
+-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
+-  FUSER_DELAY=5&lt;br /&gt;
+-done&lt;br /&gt;
+-# If fuser was run, let it have some delay:&lt;br /&gt;
+-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
+-  sleep $FUSER_DELAY&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
+-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
+-&lt;br /&gt;
+ # Try to shut down pppd:&lt;br /&gt;
+ PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
+ if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
+@@ -131,45 +97,11 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Bring down the networking system, but first make sure that this&lt;br /&gt;
+-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
+-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
+-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
+-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
+-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
+-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
+-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
+-  # restore themselves.&lt;br /&gt;
+-  sleep 2&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Shut down PCMCIA devices:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
+-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
+-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
+-  /bin/sleep 5&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Turn off process accounting:&lt;br /&gt;
+ if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
+   /sbin/accton off&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Terminate acpid before syslog:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
+-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Stop udev:&lt;br /&gt;
+-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
+-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+ # Kill all remaining processes.&lt;br /&gt;
+ if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
+   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
+@@ -187,16 +119,6 @@&lt;br /&gt;
+   fi&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Carry a random seed between reboots.&lt;br /&gt;
+-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
+-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
+-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
+-else&lt;br /&gt;
+-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
+-fi&lt;br /&gt;
+-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
+-&lt;br /&gt;
+ # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
+ $command -w&lt;br /&gt;
+ &lt;br /&gt;
+@@ -205,80 +127,5 @@&lt;br /&gt;
+   rm -f /var/lock/subsys/*&lt;br /&gt;
+ fi&lt;br /&gt;
+ &lt;br /&gt;
+-# Turn off swap:&lt;br /&gt;
+-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
+-/sbin/swapoff -a&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
+-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
+-&lt;br /&gt;
+-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
+-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
+-&lt;br /&gt;
+ # This never hurts:&lt;br /&gt;
+ /bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# Close any volumes opened by cryptsetup:&lt;br /&gt;
+-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
+-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
+-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
+-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
+-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
+-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
+-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
+-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
+-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
+-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
+-      # then run mkswap on the underlying device -&lt;br /&gt;
+-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
+-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
+-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
+-      mkswap $DEV&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  done&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Deactivate LVM volume groups:&lt;br /&gt;
+-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
+-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
+-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
+-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
+-# remounted as read-only first)&lt;br /&gt;
+-/bin/sync&lt;br /&gt;
+-&lt;br /&gt;
+-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
+-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
+-/bin/sleep 3&lt;br /&gt;
+-&lt;br /&gt;
+-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
+-wait&lt;br /&gt;
+-&lt;br /&gt;
+-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
+-  # See if this is a powerfail situation:&lt;br /&gt;
+-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
+-    # Signal UPS to shut off the inverter:&lt;br /&gt;
+-    /sbin/genpowerd -k&lt;br /&gt;
+-    if [ ! $? = 0 ]; then&lt;br /&gt;
+-      echo&lt;br /&gt;
+-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
+-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
+-      # Wasting 15 seconds of precious power:&lt;br /&gt;
+-      /bin/sleep 15&lt;br /&gt;
+-    fi&lt;br /&gt;
+-  fi&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
+-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
+-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
+-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
+-  /sbin/reboot&lt;br /&gt;
+-else&lt;br /&gt;
+-  /sbin/poweroff&lt;br /&gt;
+-fi&lt;br /&gt;
+-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2013-10-28 06:07:17.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2013-12-29 12:14:08.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S	2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2013-12-29 12:13:33.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2013-12-29T13:33:00Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Make the guest */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1** (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
    mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
    do&lt;br /&gt;
        IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
        PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                    wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
# Thanks to Mark Colclough for corrections&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.YOURDOMAIN.XY&lt;br /&gt;
IP=10.0.0.182&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=5182&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
    echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot;&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg --root $VDIR/$NAME *.t?z;&lt;br /&gt;
ROOT=$VDIR/$NAME upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab&lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
    if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
              echo&lt;br /&gt;
        echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
    fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.11.08&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2013-11-08 22:22:26.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S   2013-11-08 22:19:49.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2013-11-08 22:29:16.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2013-12-29T13:31:26Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1** (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2013.12.29&lt;br /&gt;
# Now the script parses comments in the package list (thanks to Mark Colclough)&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you want to download the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
    mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do&lt;br /&gt;
            [ &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            [ &amp;quot;${LINE#\#}&amp;quot; = &amp;quot;$LINE&amp;quot; ] || continue&lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
    exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
    do&lt;br /&gt;
        IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                [ &amp;quot;${PKG#\#}&amp;quot; = &amp;quot;${PKG}&amp;quot; ] || continue&lt;br /&gt;
        PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                    wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
            fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
    echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that ''/etc/resolv.conf /etc/localtime /etc/profile'' are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.11.08&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2013-11-08 22:22:26.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S   2013-11-08 22:19:49.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2013-11-08 22:29:16.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2013-11-10T14:04:03Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware &amp;lt;b&amp;gt;14.1&amp;lt;/b&amp;gt;, 14.0, 13.37 and 13.1** (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package ''PKG_LIST'', enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that ''/etc/resolv.conf /etc/localtime /etc/profile'' are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.11.08&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2013-11-08 22:22:26.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S   2013-11-08 22:19:49.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2013-11-08 22:29:16.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2013-11-08T22:17:11Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package ''PKG_LIST'', enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that ''/etc/resolv.conf /etc/localtime /etc/profile'' are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.11.08&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2013-11-08 22:22:26.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S   2013-11-08 22:19:49.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2013-11-08 22:29:16.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2013-11-08T22:16:49Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;linux-vserver_slackware-14.1.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package ''PKG_LIST'', enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that ''/etc/resolv.conf /etc/localtime /etc/profile'' are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.11.08&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2013-11-08 22:22:26.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S   2013-11-08 22:19:49.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2013-11-08 22:29:16.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2013-11-08T21:51:17Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Patch applayed */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package ''PKG_LIST'', enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that ''/etc/resolv.conf /etc/localtime /etc/profile'' are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.1 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2013.11.08&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -ruN rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2013-09-23 01:43:20.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2013-11-08 22:15:10.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,24 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
 # Try to shut down pppd:&lt;br /&gt;
 PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
 if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
@@ -131,45 +97,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +119,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 4096 bits:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(expr $(cat /proc/sys/kernel/random/poolsize) / 8) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,80 +127,5 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Close any volumes opened by cryptsetup:&lt;br /&gt;
-if [ -f /etc/crypttab -a -x /sbin/cryptsetup ]; then&lt;br /&gt;
-  cat /etc/crypttab | grep -v &amp;quot;^#&amp;quot; | grep -v &amp;quot;^$&amp;quot; | while read line; do&lt;br /&gt;
-    # NOTE: we only support LUKS formatted volumes (except for swap)!&lt;br /&gt;
-    LUKS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f1 -d' ')&lt;br /&gt;
-    DEV=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f2 -d' ')&lt;br /&gt;
-    OPTS=$(echo $line | tr '\t' ' ' | tr -s ' ' | cut -f4 -d' ')&lt;br /&gt;
-    if /sbin/cryptsetup isLuks $DEV 2&amp;gt;/dev/null ; then&lt;br /&gt;
-      echo &amp;quot;Locking LUKS crypt volume '${LUKS}':&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup luksClose ${LUKS}&lt;br /&gt;
-    elif echo $OPTS | grep -wq swap ; then&lt;br /&gt;
-      # If any of the volumes was used as encrypted swap,&lt;br /&gt;
-      # then run mkswap on the underlying device -&lt;br /&gt;
-      # in case other Linux installations on this computer should use it:&lt;br /&gt;
-      echo &amp;quot;Erasing encrypted swap '${LUKS}' and restoring normal swap on ${DEV}:&amp;quot;&lt;br /&gt;
-      /sbin/cryptsetup remove ${LUKS}&lt;br /&gt;
-      mkswap $DEV&lt;br /&gt;
-    fi&lt;br /&gt;
-  done&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
-# This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
-wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -ruN rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2013-11-08 22:22:26.000000000 +0100&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -ruN rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2013-10-28 06:06:39.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.S   2013-11-08 22:19:49.000000000 +0100&lt;br /&gt;
@@ -48,31 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    # See linux-*/Documentation/cgroups/cgroups.txt (section 1.6)&lt;br /&gt;
-    # Check if we have some tools to autodetect the available cgroup controllers&lt;br /&gt;
-    if [ -x /usr/bin/lssubsys -a -x /usr/bin/tr -a -x /usr/bin/sed ]; then&lt;br /&gt;
-      # Mount a tmpfs as the cgroup filesystem root&lt;br /&gt;
-      mount -t tmpfs -o mode=0755 cgroup_root /sys/fs/cgroup&lt;br /&gt;
-      # Autodetect available controllers and mount them in subfolders&lt;br /&gt;
-      controllers=&amp;quot;$(lssubsys -a 2&amp;gt;/dev/null | tr '\n' ' ' | sed s/.$//)&amp;quot;&lt;br /&gt;
-      for i in $controllers; do&lt;br /&gt;
-        mkdir /sys/fs/cgroup/$i&lt;br /&gt;
-        mount -t cgroup -o $i $i /sys/fs/cgroup/$i&lt;br /&gt;
-      done&lt;br /&gt;
-      unset i controllers&lt;br /&gt;
-    else&lt;br /&gt;
-      # We can't use autodetection so fall back mounting them all together&lt;br /&gt;
-      mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-    fi&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -ruN rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2013-06-22 22:49:03.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2013-11-08 22:29:16.000000000 +0100&lt;br /&gt;
@@ -5,7 +5,7 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
     echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
@@ -16,10 +16,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2013-11-08T21:49:37Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Make the guest */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package ''PKG_LIST'', enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.1 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that ''/etc/resolv.conf /etc/localtime /etc/profile'' are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2013-11-08T21:48:59Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.1&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package ''PKG_LIST'', enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that ''/etc/resolv.conf /etc/localtime /etc/profile'' are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-10-19T20:29:14Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware{$ARCH}-{$VERSION}_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh script''.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages or empty otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package ''PKG_LIST'', enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that ''/etc/resolv.conf /etc/localtime /etc/profile'' are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-10-19T20:26:46Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Make the guest */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the slackware{$ARCH}-{$VERSION}_pkg folder. If not, adjust its location editing the make_slack_vserver.sh script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages and blank otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package ''PKG_LIST'', enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that ''/etc/resolv.conf /etc/localtime /etc/profile'' are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-10-19T20:26:22Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Make the guest */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the slackware{$ARCH}-{$VERSION}_pkg folder. If not, adjust its location editing the make_slack_vserver.sh script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages and blank otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package ''PKG_LIST'', enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the rc.* startup scripts removing all the hardware related daemons, and finally replace the /dev dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that ''/etc/resolv.conf /etc/localtime /etc/profile'' are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-10-19T20:25:13Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the slackware{$ARCH}-{$VERSION}_pkg folder. If not, adjust its location editing the make_slack_vserver.sh script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script ''download_slack_pkg.sh''. It can create a folder like ''slackware{$ARCH}-{$VERSION}_pkg'' for you, where ''$ARCH'' has to be &amp;quot;64&amp;quot; if you want to download 64b packages and blank otherwise, while ''$VERSION'' is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package ''PKG_LIST'', enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the ''/slackware'' folder with the updates belonging to the ''/patches'' dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the rc.* startup scripts removing all the hardware related daemons, and finally replace the /dev dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script make_slack_vserver.sh:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that /etc/resolv.conf /etc/localtime /etc/profile are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-10-01T17:05:00Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the slackware{$ARCH}-{$VERSION}_pkg folder. If not, adjust its location editing the make_slack_vserver.sh script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh. It can create a folder like &amp;lt;em&amp;gt;slackware{$ARCH}-{$VERSION}_pkg&amp;lt;/em&amp;gt; for you, where &amp;lt;em&amp;gt;$ARCH&amp;lt;/em&amp;gt; has to be &amp;quot;64&amp;quot; if you want to download 64b packages and null otherwise, while &amp;lt;em&amp;gt;$VERSION&amp;lt;/em&amp;gt; is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package PKG_LIST, enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the /slackware folder with the updates belonging to the /patches dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the rc.* startup scripts removing all the hardware related daemons, and finally replace the /dev dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script make_slack_vserver.sh:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that /etc/resolv.conf /etc/localtime /etc/profile are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-10-01T17:03:17Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working.&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware. Comments would be welcome about this :-).&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the slackware{$ARCH}-{$VERSION}_pkg folder. If not, adjust its location editing the make_slack_vserver.sh script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh. It can create a folder like &amp;lt;em&amp;gt;slackware{$ARCH}-{$VERSION}_pkg&amp;lt;/em&amp;gt; for you, where &amp;lt;em&amp;gt;$ARCH&amp;lt;/em&amp;gt; has to be &amp;quot;64&amp;quot; if you want to download 64b packages and null otherwise, while &amp;lt;em&amp;gt;$VERSION&amp;lt;/em&amp;gt; is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package PKG_LIST, enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the /slackware folder with the updates belonging to the /patches dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the rc.* startup scripts removing all the hardware related daemons, and finally replace the /dev dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script make_slack_vserver.sh:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that /etc/resolv.conf /etc/localtime /etc/profile are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-09-29T14:39:48Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Contact */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working. You can find here a quick and easy howto concerning Linux-Vserver installation and configuration (patching the kernel + utils-vserver installation).&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware. Comments would be welcome about this :-).&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the slackware{$ARCH}-{$VERSION}_pkg folder. If not, adjust its location editing the make_slack_vserver.sh script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh. It can create a folder like &amp;lt;em&amp;gt;slackware{$ARCH}-{$VERSION}_pkg&amp;lt;/em&amp;gt; for you, where &amp;lt;em&amp;gt;$ARCH&amp;lt;/em&amp;gt; has to be &amp;quot;64&amp;quot; if you want to download 64b packages and null otherwise, while &amp;lt;em&amp;gt;$VERSION&amp;lt;/em&amp;gt; is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package PKG_LIST, enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the /slackware folder with the updates belonging to the /patches dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the rc.* startup scripts removing all the hardware related daemons, and finally replace the /dev dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script make_slack_vserver.sh:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that /etc/resolv.conf /etc/localtime /etc/profile are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments and criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-09-29T14:39:21Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Patch applayed */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working. You can find here a quick and easy howto concerning Linux-Vserver installation and configuration (patching the kernel + utils-vserver installation).&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware. Comments would be welcome about this :-).&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the slackware{$ARCH}-{$VERSION}_pkg folder. If not, adjust its location editing the make_slack_vserver.sh script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh. It can create a folder like &amp;lt;em&amp;gt;slackware{$ARCH}-{$VERSION}_pkg&amp;lt;/em&amp;gt; for you, where &amp;lt;em&amp;gt;$ARCH&amp;lt;/em&amp;gt; has to be &amp;quot;64&amp;quot; if you want to download 64b packages and null otherwise, while &amp;lt;em&amp;gt;$VERSION&amp;lt;/em&amp;gt; is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package PKG_LIST, enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the /slackware folder with the updates belonging to the /patches dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the rc.* startup scripts removing all the hardware related daemons, and finally replace the /dev dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script make_slack_vserver.sh:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that /etc/resolv.conf /etc/localtime /etc/profile are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Comments, criticism can be addressed to roberto dot puzzanghera at sagredo dot eu (http://sagredo.eu)&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-09-29T14:35:39Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working. You can find here a quick and easy howto concerning Linux-Vserver installation and configuration (patching the kernel + utils-vserver installation).&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;em&amp;gt;PKG_LIST&amp;lt;/em&amp;gt; is the package list to be installed in the guest&lt;br /&gt;
* &amp;lt;em&amp;gt;download_slack_pkg.sh&amp;lt;/em&amp;gt; is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* &amp;lt;em&amp;gt;make_slack_vserver.sh&amp;lt;/em&amp;gt; is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* &amp;lt;em&amp;gt;rc&amp;lt;/em&amp;gt; is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* &amp;lt;em&amp;gt;slackware-14.0.patch&amp;lt;/em&amp;gt; is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware. Comments would be welcome about this :-).&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the slackware{$ARCH}-{$VERSION}_pkg folder. If not, adjust its location editing the make_slack_vserver.sh script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh. It can create a folder like &amp;lt;em&amp;gt;slackware{$ARCH}-{$VERSION}_pkg&amp;lt;/em&amp;gt; for you, where &amp;lt;em&amp;gt;$ARCH&amp;lt;/em&amp;gt; has to be &amp;quot;64&amp;quot; if you want to download 64b packages and null otherwise, while &amp;lt;em&amp;gt;$VERSION&amp;lt;/em&amp;gt; is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package PKG_LIST, enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the /slackware folder with the updates belonging to the /patches dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the rc.* startup scripts removing all the hardware related daemons, and finally replace the /dev dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script make_slack_vserver.sh:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that /etc/resolv.conf /etc/localtime /etc/profile are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-09-29T14:34:41Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working. You can find here a quick and easy howto concerning Linux-Vserver installation and configuration (patching the kernel + utils-vserver installation).&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* PKG_LIST is the package list to be installed in the guest&lt;br /&gt;
* download_slack_pkg.sh is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* make_slack_vserver.sh is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* rc is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* slackware-14.0.patch is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware. Comments would be welcome about this :-).&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the slackware{$ARCH}-{$VERSION}_pkg folder. If not, adjust its location editing the make_slack_vserver.sh script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh. It can create a folder like &amp;lt;em&amp;gt;slackware{$ARCH}-{$VERSION}_pkg&amp;lt;/em&amp;gt; for you, where &amp;lt;em&amp;gt;$ARCH&amp;lt;/em&amp;gt; has to be &amp;quot;64&amp;quot; if you want to download 64b packages and null otherwise, while &amp;lt;em&amp;gt;$VERSION&amp;lt;/em&amp;gt; is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package PKG_LIST, enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the /slackware folder with the updates belonging to the /patches dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the rc.* startup scripts removing all the hardware related daemons, and finally replace the /dev dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script make_slack_vserver.sh:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that /etc/resolv.conf /etc/localtime /etc/profile are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_14</id>
		<title>Installation on Slackware 14</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_14"/>
				<updated>2012-09-29T14:33:12Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: Created page with 'The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux…'&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this note is to setup a guest based on Slackware. What follows was tested on Slackware 14.0, 13.37 and 13.1 (both 32b and 64b). I will assume that you have a Linux-Vserver box working. You can find here a quick and easy howto concerning Linux-Vserver installation and configuration (patching the kernel + utils-vserver installation).&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wget http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver&lt;br /&gt;
ls&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You have downloaded the following files:&lt;br /&gt;
&lt;br /&gt;
* PKG_LIST is the package list to be installed in the guest&lt;br /&gt;
* download_slack_pkg.sh is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware[64]-version_pkg sub-folder.&lt;br /&gt;
* make_slack_vserver.sh is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* rc is the startup script for the virtual server. It will be automatically copied in /etc/rc.d* /init.d/rc&lt;br /&gt;
* slackware-14.0.patch is the patch which modify rc.0, rc.6 rc.M, rc.S, rc.inet2 and rc.syslog. It must be applyed after the creation of the vserver process. In the patch I switched off all the mounts and executable that are related to the hardware. Comments would be welcome about this :-).&lt;br /&gt;
&lt;br /&gt;
== Download the packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. This list of 110 packages is based on the Minimal System reported at http://slackwiki.org/Minimal_System without all hardware, kernel and multimedia related packages. The install leads to a guest of about 448M of size. This set fits with the installation of a complete virtual web server including apache, apache-tomcat, php, mysql, postgresql, qmail and related, ftp, named.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the slackware{$ARCH}-{$VERSION}_pkg folder. If not, adjust its location editing the make_slack_vserver.sh script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh. It can create a folder like slackware{$ARCH}-{$VERSION}_pkg for you, where $ARCH has to be &amp;quot;64&amp;quot; if you want to download 64b packages and null otherwise, while $VERSION is the Slackware version, so it's something like &amp;quot;14.0&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
&lt;br /&gt;
VERSION=&amp;quot;14.0&amp;quot; # Slackware version&lt;br /&gt;
ARCH=&amp;quot;64&amp;quot; # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware${ARCH}-${VERSION}/&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# put here your pkg list&lt;br /&gt;
LIST=&amp;quot;${PWD}/PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# create the folder where the pkg will be downloaded&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        mkdir -p $PACKAGES&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# create the &amp;quot;patches&amp;quot; sub-folder&lt;br /&gt;
if [ ! -d &amp;quot;${PACKAGES}/patches&amp;quot; ]; then&lt;br /&gt;
        mkdir -p &amp;quot;${PACKAGES}/patches&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# download&lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;${SRC}slackware${ARCH}/${LINE}*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&lt;br /&gt;
# download packages from the patches folder&lt;br /&gt;
cd ${PACKAGES}/patches&lt;br /&gt;
&lt;br /&gt;
if [ -f ${LIST} ]; then&lt;br /&gt;
        while read LINE&lt;br /&gt;
        do&lt;br /&gt;
                IFS='/' read -ra PKG &amp;lt;&amp;lt;&amp;lt; &amp;quot;$LINE&amp;quot;&lt;br /&gt;
                PKG_LEN=${#PKG[@]}&lt;br /&gt;
                if [ $PKG_LEN == 2 ]; then&lt;br /&gt;
                        wget &amp;quot;${SRC}patches/packages/${PKG[1]}*.t?z&amp;quot;&lt;br /&gt;
                fi&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
        echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
                                            &lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package PKG_LIST, enter your favorite ftp server and run from the command line&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NB: this script tries also to overwrite the packages downloaded from the /slackware folder with the updates belonging to the /patches dir.&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the rc.* startup scripts removing all the hardware related daemons, and finally replace the /dev dir.&lt;br /&gt;
&lt;br /&gt;
This is done adjusting and running the script make_slack_vserver.sh:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2012.09.29&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
&lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=test&lt;br /&gt;
HOSTNAME=$NAME.domain.com&lt;br /&gt;
IP=10.0.0.34&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=34000&lt;br /&gt;
VERSION=14.0 # Slackware version&lt;br /&gt;
ARCH=64 # you can put 64 for 64b cpu just to separate 64/32 download folders&lt;br /&gt;
&lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/usr/local/vservers&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
&lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;${SETUP}/slackware${ARCH}-${VERSION}_pkg&amp;quot;&lt;br /&gt;
&lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;${SETUP}/rc&amp;quot;&lt;br /&gt;
&lt;br /&gt;
################### end configuration&lt;br /&gt;
&lt;br /&gt;
# sanity check&lt;br /&gt;
&lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z;&lt;br /&gt;
upgradepkg patches/*.t?z;&lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
&lt;br /&gt;
        if [ ! -f &amp;quot;${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot; ]; then&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;Can't find any PATCH here: ${SETUP}/linux-vserver_slackware-${VERSION}.patch&amp;quot;&lt;br /&gt;
                echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                exit 1&lt;br /&gt;
        fi&lt;br /&gt;
&lt;br /&gt;
        cd ${VDIR}/${NAME}/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; ${SETUP}/linux-vserver_slackware-${VERSION}.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Note that /etc/resolv.conf /etc/localtime /etc/profile are copied form the host.&lt;br /&gt;
&lt;br /&gt;
Edit the script inserting at least the NAME, the IP and the CONTEXT. The packages' location should be ok if you downloaded them using my script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./make_slack_vserver.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-14.0.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inside the tarball you can find the old patch for Slackware 13.1 and 13.37, if you like.&lt;br /&gt;
&lt;br /&gt;
== Post installation tasks ==&lt;br /&gt;
&lt;br /&gt;
Put this inside your rc.local:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
/usr/local/etc/rc.d/init.d/vprocunhide  start&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Start the new server ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Patch applayed ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 14.0 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2012.09.29&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0   2012-09-29 15:23:23.347807225 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6  2012-08-15 01:03:12.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6   2012-09-29 15:23:23.363807355 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
                ;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,32 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Shut down YP services:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.yp ]; then&lt;br /&gt;
   if grep -wq stop /etc/rc.d/rc.yp ; then&lt;br /&gt;
@@ -131,45 +89,11 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Stop udev:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.udev force-stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all remaining processes.&lt;br /&gt;
 if [ ! &amp;quot;$1&amp;quot; = &amp;quot;fast&amp;quot; ]; then&lt;br /&gt;
   echo &amp;quot;Sending all processes the SIGTERM signal.&amp;quot;&lt;br /&gt;
@@ -187,16 +111,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -205,17 +119,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -240,45 +143,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M  2012-09-25 19:47:07.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.M   2012-09-29 15:33:01.756524040 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,40 +54,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Run rc.udev again.  This will start udev if it is not already running&lt;br /&gt;
-# (for example, upon return from runlevel 1), otherwise it will trigger it&lt;br /&gt;
-# to look for device changes and to generate persistent rules if needed.&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
-&lt;br /&gt;
-# Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.ntpd start&lt;br /&gt;
@@ -135,17 +77,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -183,18 +114,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd or networkmanager:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd -a -x /usr/sbin/wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.networkmanager ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.networkmanager start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -207,60 +126,11 @@&lt;br /&gt;
   /usr/bin/update-pango-querymodules --verbose&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start dnsmasq, a simple DHCP/DNS server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.dnsmasq ]; then&lt;br /&gt;
-  /etc/rc.d/rc.dnsmasq start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start snmpd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.snmpd ]; then&lt;br /&gt;
   /etc/rc.d/rc.snmpd start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the print spooling system.  This will usually be LPRng (lpd) or CUPS.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.cups ]; then&lt;br /&gt;
-  # Start CUPS:&lt;br /&gt;
-  /etc/rc.d/rc.cups start&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.lprng ]; then&lt;br /&gt;
-  # Start LPRng (lpd):&lt;br /&gt;
-  . /etc/rc.d/rc.lprng start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start netatalk. (a file/print server for Macs using Appletalk)&lt;br /&gt;
-if [ -x /etc/rc.d/rc.atalk ]; then&lt;br /&gt;
-  /etc/rc.d/rc.atalk start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -325,11 +195,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -361,11 +226,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.S rc.d/rc.S&lt;br /&gt;
--- rc.d-original/rc.S  2012-09-13 21:38:34.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.S   2012-09-29 15:23:23.391807582 +0200&lt;br /&gt;
@@ -48,16 +48,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount Control Groups filesystem interface:&lt;br /&gt;
-if grep -wq cgroup /proc/filesystems ; then&lt;br /&gt;
-  if [ -d /sys/fs/cgroup ]; then&lt;br /&gt;
-    mount -t cgroup cgroup /sys/fs/cgroup&lt;br /&gt;
-  else&lt;br /&gt;
-    mkdir -p /dev/cgroup&lt;br /&gt;
-    mount -t cgroup cgroup /dev/cgroup&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the Logical Volume Manager.&lt;br /&gt;
 # This won't start unless we find /etc/lvmtab (LVM1) or&lt;br /&gt;
 # /etc/lvm/backup/ (LVM2).  This is created by /sbin/vgscan, so to&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2      2012-08-15 00:53:35.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2       2012-09-29 15:23:23.403807679 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog     2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog      2012-09-29 15:23:23.419807809 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Documentation</id>
		<title>Documentation</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Documentation"/>
				<updated>2012-09-29T14:23:46Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Installation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;margin: 2em auto 2em auto; padding: 10px; background-color: #F9ECCD; border: 1px solid #004433; text-align: center;&amp;quot;&amp;gt;&lt;br /&gt;
[[Image:Icon-Caution.png|left]]&lt;br /&gt;
We are currently migrating to MediaWiki from our old system, but not all content has been migrated yet. Take a look at the [[Wiki Team]] page for instructions how to help or look at the [http://oldwiki.linux-vserver.org old wiki] to find the information not migrated yet.&lt;br /&gt;
&lt;br /&gt;
'''To ease migration we created a [[List of old Documentation pages]].'''&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
* [[Overview|Virtualization Overview]]&lt;br /&gt;
* [[Usage Scenarios]]&lt;br /&gt;
* [[Feature Matrix]]&lt;br /&gt;
&lt;br /&gt;
== Installation ==&lt;br /&gt;
&lt;br /&gt;
* [[Installation Considerations]]&lt;br /&gt;
* [[Installation on Linux 2.6]]: from source, both the kernel and util-vserver&lt;br /&gt;
* [[Installation on ArchLinux]]&lt;br /&gt;
* [[Installation on CentOS]]&lt;br /&gt;
* [[Installation on Debian]]&lt;br /&gt;
* [[Installation on Fedora]]&lt;br /&gt;
* [[Installation on Gentoo]]&lt;br /&gt;
* [[Installation on Mandrake]]&lt;br /&gt;
* [http://www.pld-linux.org/Docs/Vserver Installation on PLD-Linux]&lt;br /&gt;
* [[Installation on Redhat]]&lt;br /&gt;
* [[Installation on Slackware]]&lt;br /&gt;
** [[Installation on Slackware 14]]&lt;br /&gt;
* [[Installation on SuSE/OpenSUSE]]&lt;br /&gt;
* [[Installation on Ubuntu]]&lt;br /&gt;
&lt;br /&gt;
== Configuration ==&lt;br /&gt;
&lt;br /&gt;
* [[Util-vserver:Documentation|util-vserver Documentation]]&lt;br /&gt;
* [[vcd:Documentation|VServer Control Daemon Documentation]]&lt;br /&gt;
* [[Share a directory among multiple guests]]&lt;br /&gt;
* [[Standard_non-shared_quota]]&lt;br /&gt;
&lt;br /&gt;
== Guides and Howtos ==&lt;br /&gt;
&lt;br /&gt;
* [[Building Guest Systems]]&lt;br /&gt;
* [[util-vserver:Howto virtualize an exisiting Linux server|Howto virtualize an existing Linux server]]&lt;br /&gt;
* [[VCMD HowTo]]&lt;br /&gt;
* [[Howto make bsd-style init sysv-compatible|Howto make Bsd-style init sysv-compatible (archlinux guest system)]]&lt;br /&gt;
* [[Installing 32-bit Fedora on 64-bit Debian]]&lt;br /&gt;
* [[Installing Ubuntu on Debian]]&lt;br /&gt;
* [[Installing an openSUSE vserver guest]]&lt;br /&gt;
* [[Networking vserver guests]]&lt;br /&gt;
* [[Howto HostAuth]]&lt;br /&gt;
* [[Fuse_GlusterFS| Fuse and GlusterFS]]&lt;br /&gt;
* [[yum-patch|How to patch vyum]]&lt;br /&gt;
* [[yum-upgrade-3.2.4|Upgrading existing installations to yum-3.2.4]]&lt;br /&gt;
* [[Migrating from OpenVZ to Linux-Vserver]]&lt;br /&gt;
* [[Getting_high_with_lenny]]&lt;br /&gt;
* [[Installing_Ubuntu_8.04_Hardy_as_guest]]&lt;br /&gt;
* [[Applying CPU Limits]]&lt;br /&gt;
* [[Upgrading from Etch to Lenny]]&lt;br /&gt;
* [[Upstart issues]]&lt;br /&gt;
* [[Limit Networking on Multihomed hosts]]&lt;br /&gt;
* [[Read-only_RootFS]]&lt;br /&gt;
&lt;br /&gt;
== Lists &amp;amp;amp; Theory ==&lt;br /&gt;
&lt;br /&gt;
* Basic configuration&lt;br /&gt;
** [[Capabilities and Flags]]&lt;br /&gt;
** [[CPU Scheduler]]&lt;br /&gt;
** [[Disk Limits and Quota]]&lt;br /&gt;
** [[Resource Limits]]&lt;br /&gt;
*** [[Memory Limits]]&lt;br /&gt;
*** [[Network Bandwidth Management]]&lt;br /&gt;
** [[Virtual System Information]]&lt;br /&gt;
** [[Unification]]&lt;br /&gt;
&lt;br /&gt;
* Security Considerations&lt;br /&gt;
** [[Secure Capabilities]]&lt;br /&gt;
** [[Secure chroot Barrier]]&lt;br /&gt;
** [[Secure Device Nodes]]&lt;br /&gt;
** [[Secure ProcFS Entries]]&lt;br /&gt;
&lt;br /&gt;
* Performance and Stability&lt;br /&gt;
** [[Virtualization Overhead]]&lt;br /&gt;
&lt;br /&gt;
* Implementation Details&lt;br /&gt;
** [[Context Accounting]]&lt;br /&gt;
** [[Filesystem Attributes]]&lt;br /&gt;
** [[Filesystem Tagging]]&lt;br /&gt;
** [[Filesystem Namespaces]]&lt;br /&gt;
** [[Kernel Userspace Helper]]&lt;br /&gt;
** [[Mainline Kernel Virtualization]]&lt;br /&gt;
** [[ProcFS]]&lt;br /&gt;
** [[Syscall Command Switch]]&lt;br /&gt;
&lt;br /&gt;
== External Resources ==&lt;br /&gt;
&lt;br /&gt;
* [http://vserver.13thfloor.at/Remote-Reset/ Simple Remote reset] (remote reset/power your vserver box)&lt;br /&gt;
* [http://vserver.13thfloor.at/Null-Modem/ NullModem cables] [http://www.loop-back.com/null-mod.html II] [http://www.tldp.org/HOWTO/Remote-Serial-Console-HOWTO/serial-pc-terminal.html III] (cable required for serial console)&lt;br /&gt;
* [http://www.tldp.org/HOWTO/Remote-Serial-Console-HOWTO/index.html Serial Console HOWTO]&lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation| ]]&lt;br /&gt;
[[Category:Community]]&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-07-28T20:59:12Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the slack packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.37.patch] is the patch which modify ''rc.6'' ''rc.M'' and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.37/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.37/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [http://linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:41:03Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Apply the patch and start the guest */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.37.patch] is the patch which modify ''rc.6'' ''rc.M'' and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [http://linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:39:26Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the slack packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.37.patch] is the patch which modify ''rc.6'' ''rc.M'' and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [http://linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:37:06Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the slack packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.37.patch] is the patch which modify ''rc.6'' ''rc.M'' and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [[PKG_LIST Slackware_package_list]], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:35:54Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the slack packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.37.patch] is the patch which modify ''rc.6'' ''rc.M'' and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [[Slackware_package_list PKG_LIST]], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:35:29Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the slack packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.37.patch] is the patch which modify ''rc.6'' ''rc.M'' and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [#Slackware_package_list PKG_LIST], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:33:42Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the slack packages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.37.patch] is the patch which modify ''rc.6'' ''rc.M'' and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST PKG_LIST], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:31:41Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the patch and the installer script */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.37.patch] is the patch which modify ''rc.6'' ''rc.M'' and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST PKG_LIST], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:31:06Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Download the patch and the installer script */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.37.patch] is the patch which modify ''rc.6'' ''rc.M and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST PKG_LIST], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:29:06Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Slackware package list */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.1.patch] is the patch which modify ''rc.6'' ''rc.M and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST PKG_LIST], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:27:57Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Patch used */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.1.patch] is the patch which modify ''rc.6'' ''rc.M and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST PKG_LIST], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.37 guest on a Linux-Vserver host&lt;br /&gt;
========================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2011.04.28&lt;br /&gt;
&lt;br /&gt;
========================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.0	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2011-04-16 23:14:14.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.6	2011-04-28 15:01:59.000000000 +0200&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,66 +82,11 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Kill any processes (typically gam) that would otherwise prevent&lt;br /&gt;
-# unmounting NFS volumes:&lt;br /&gt;
-unset FUSER_DELAY&lt;br /&gt;
-for dir in $(/bin/mount | grep 'type nfs' | cut -d ' ' -f 3 ) ; do&lt;br /&gt;
-  echo &amp;quot;Killing processes holding NFS mount $dir open...&amp;quot;&lt;br /&gt;
-  # Background this to prevent fuser from also blocking shutdown:&lt;br /&gt;
-  /usr/bin/fuser -k -m $dir &amp;amp;&lt;br /&gt;
-  FUSER_DELAY=5&lt;br /&gt;
-done&lt;br /&gt;
-# If fuser was run, let it have some delay:&lt;br /&gt;
-if [ ! -z &amp;quot;$FUSER_DELAY&amp;quot; ]; then&lt;br /&gt;
-  sleep $FUSER_DELAY&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -l -f -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Bring down the networking system, but first make sure that this&lt;br /&gt;
-# isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
-if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
-  if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-    . /etc/rc.d/rc.inet1 stop&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# In case dhcpcd might have been manually started on the command line,&lt;br /&gt;
-# look for the .pid file, and shut dhcpcd down if it's found:&lt;br /&gt;
-if /bin/ls /etc/dhcpc/*.pid 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  /sbin/dhcpcd -k 1&amp;gt; /dev/null 2&amp;gt; /dev/null&lt;br /&gt;
-  # A little time for /etc/resolv.conf and/or other files to&lt;br /&gt;
-  # restore themselves.&lt;br /&gt;
-  sleep 2&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 # INIT is supposed to handle this entirely now, but this didn't always&lt;br /&gt;
 # work correctly without this second pass at killing off the processes.&lt;br /&gt;
@@ -177,16 +106,6 @@&lt;br /&gt;
   fi&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Carry a random seed between reboots.&lt;br /&gt;
-echo &amp;quot;Saving random seed from /dev/urandom in /etc/random-seed.&amp;quot;&lt;br /&gt;
-# Use the pool size from /proc, or 512 bytes:&lt;br /&gt;
-if [ -r /proc/sys/kernel/random/poolsize ]; then&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=$(cat /proc/sys/kernel/random/poolsize) 2&amp;gt; /dev/null&lt;br /&gt;
-else&lt;br /&gt;
-  /bin/dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2&amp;gt; /dev/null&lt;br /&gt;
-fi&lt;br /&gt;
-/bin/chmod 600 /etc/random-seed&lt;br /&gt;
-&lt;br /&gt;
 # Before unmounting file systems write a reboot or halt record to wtmp.&lt;br /&gt;
 $command -w&lt;br /&gt;
 &lt;br /&gt;
@@ -195,17 +114,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -230,45 +138,10 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
 # to deactivate the / logical volume...  but at least it was&lt;br /&gt;
 # remounted as read-only first)&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2011-03-22 07:15:15.000000000 +0100&lt;br /&gt;
+++ rc.d/rc.M	2011-04-28 19:07:47.000000000 +0200&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -47,31 +43,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -83,38 +54,18 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Initialize the networking hardware.&lt;br /&gt;
-if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.inet1&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
 # Mount any additional filesystem types that haven't already been mounted:&lt;br /&gt;
-mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
+#mount -a -v 2&amp;gt; /dev/null | grep -v &amp;quot;already mounted&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 # Start the Control Script for automounter:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
-fi&lt;br /&gt;
+#if [ -x /etc/rc.d/rc.autofs ]; then&lt;br /&gt;
+#  sh /etc/rc.d/rc.autofs start&lt;br /&gt;
+#fi&lt;br /&gt;
 &lt;br /&gt;
 # Start the Network Time Protocol daemon:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.ntpd ]; then&lt;br /&gt;
@@ -134,17 +85,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -177,21 +117,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.consolekit start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start HAL:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.hald ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.hald start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Start wicd:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.wicd start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # These GTK+/pango files need to be kept up to date for&lt;br /&gt;
 # proper input method, pixbuf loaders, and font support.&lt;br /&gt;
 if [ -x /usr/bin/update-gtk-immodules ]; then&lt;br /&gt;
@@ -228,36 +153,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -322,11 +217,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -358,11 +248,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.inet2	2011-04-28 19:09:27.000000000 +0200&lt;br /&gt;
@@ -16,26 +16,6 @@&lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
@@ -44,23 +24,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.rpc start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Mount remote CIFS filesystems.  Note that where possible, using CIFS is&lt;br /&gt;
-# preferred over SMBFS.  SMBFS is no longer actively maintained.&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w cifs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote CIFS file systems:  /sbin/mount -a -t cifs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t cifs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t cifs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Mount remote SMB filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w smbfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  echo &amp;quot;Mounting remote SMBFS file systems:  /sbin/mount -a -t smbfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t smbfs&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t smbfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger if it is not already running (maybe because /usr&lt;br /&gt;
 # is on a network partition).&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -d /var/log -a ! -r /var/run/syslogd.pid ]; then&lt;br /&gt;
diff -urNB rc.d-original/rc.syslog rc.d/rc.syslog&lt;br /&gt;
--- rc.d-original/rc.syslog	2010-10-21 01:03:54.000000000 +0200&lt;br /&gt;
+++ rc.d/rc.syslog	2011-04-28 20:20:26.000000000 +0200&lt;br /&gt;
@@ -5,8 +5,9 @@&lt;br /&gt;
 &lt;br /&gt;
 syslogd_start() {&lt;br /&gt;
   if [ -x /usr/sbin/syslogd -a -x /usr/sbin/klogd ]; then&lt;br /&gt;
-    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
-    echo -n &amp;quot;/usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+#    echo -n &amp;quot;Starting sysklogd daemons:  &amp;quot;&lt;br /&gt;
+    echo -n &amp;quot;Starting /usr/sbin/syslogd &amp;quot;&lt;br /&gt;
+    echo&lt;br /&gt;
     /usr/sbin/syslogd&lt;br /&gt;
     # prevent syslogd/klogd race condition on SMP kernels&lt;br /&gt;
     if ps acx | grep -q udevd ; then&lt;br /&gt;
@@ -16,10 +17,10 @@&lt;br /&gt;
     else&lt;br /&gt;
       sleep 1&lt;br /&gt;
     fi&lt;br /&gt;
-    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
+#    echo &amp;quot;/usr/sbin/klogd -c 3 -x&amp;quot;&lt;br /&gt;
     # '-c 3' = display level 'error' or higher messages on console&lt;br /&gt;
     # '-x' = turn off broken EIP translation&lt;br /&gt;
-    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
+#    /usr/sbin/klogd -c 3 -x&lt;br /&gt;
   fi&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	<entry>
		<id>http://linux-vserver.at/Installation_on_Slackware_13</id>
		<title>Installation on Slackware 13</title>
		<link rel="alternate" type="text/html" href="http://linux-vserver.at/Installation_on_Slackware_13"/>
				<updated>2011-04-28T22:26:58Z</updated>
		
		<summary type="html">&lt;p&gt;Roberto.puzzanghera: /* Hints */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;What follows was tested on a Slackware 13.37 and 13.1 guest. I assume you have a Linux-Vserver host working.&lt;br /&gt;
&lt;br /&gt;
== Download the patch and the installer script ==&lt;br /&gt;
* [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/slack_vserver.tar.gz slack_vserver.tar.gz]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
tar xzf slack_vserver.tar.gz&lt;br /&gt;
cd slack_vserver &lt;br /&gt;
&lt;br /&gt;
ls &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Slackware_package_list PKG_LIST] is the package list to be installed in the guest&lt;br /&gt;
* slackware_pkg/ is the folder were the packages (txz) to be installed are stored.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Download_the_slack_packages download_slack.sh] is a script that you can use to download all the PKG_LIST. If you use this scriptlet all the package will be stored in the slackware_pkg sub-folder.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Make_the_guest make_slack_vserver.sh] is the shell script that you have to adjust. It installs the guest.&lt;br /&gt;
* [http://www.linux-vserver.org/Installation_on_Slackware_13#Patch_used slackware-13.1.patch] is the patch which modify ''rc.6'' ''rc.M and ''rc.inet2''. It must be applyed after the creation of the guest. In the patch I switched off all the mounts and executable that are related to the hardware.&lt;br /&gt;
* ''rc'' is the startup script for the virtual server. It will be automatically copied in ''/etc/rc.d/init.d/rc''&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# more rc&lt;br /&gt;
&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
if [ &amp;quot;$1&amp;quot; == &amp;quot;3&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.M&lt;br /&gt;
elif [ &amp;quot;$1&amp;quot; == &amp;quot;6&amp;quot; ]; then&lt;br /&gt;
  /etc/rc.d/rc.6&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Invalid level.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download the slack packages ==&lt;br /&gt;
&lt;br /&gt;
First of all select a minimal set of packages to be installed on the virtual server. [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST This list] of '''109 packages''' is based on the Minimal System reported at [http://slackwiki.org/Minimal_System http://slackwiki.org/Minimal_System] without all hardware, kernel and multimedia related packages. The install leads to '''a guest of about 448M of size'''.&lt;br /&gt;
&lt;br /&gt;
I assume that the packages to be installed are stored in the ''slackware_pkg'' folder. If not, adjust its location editing the ''make_slack_vserver.sh'' script.&lt;br /&gt;
&lt;br /&gt;
You can download my minimal set of packages running the shell script download_slack_pkg.sh&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.01.07 &lt;br /&gt;
# Put here your favourite Slackware repository&lt;br /&gt;
&lt;br /&gt;
SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware-13.1/slackware/&amp;quot;      # 32-bit&lt;br /&gt;
#SRC=&amp;quot;ftp://ftp.slackware.no/slackware/slackware64-13.1/slackware64/&amp;quot;  # 64-bit&lt;br /&gt;
&lt;br /&gt;
LIST=&amp;quot;../PKG_LIST&amp;quot;&lt;br /&gt;
&lt;br /&gt;
cd slackware_pkg&lt;br /&gt;
&lt;br /&gt;
if [ -f $LIST ]; then&lt;br /&gt;
        while read line  &lt;br /&gt;
            do  &lt;br /&gt;
            wget &amp;quot;$SRC$line*.t?z&amp;quot;&lt;br /&gt;
        done &amp;lt; $LIST&lt;br /&gt;
else&lt;br /&gt;
  echo &amp;quot;Can't find $LIST file.&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
&lt;br /&gt;
rm index.html*&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the package [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST PKG_LIST], enter your favorite ftp server and run from the command line&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
./download_slack_pkg.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Make the guest ==&lt;br /&gt;
&lt;br /&gt;
Now let's create the guest and install the packages. As you know you must choose at least a &amp;quot;name&amp;quot;, a &amp;quot;context&amp;quot; and an ip. In addition you have to modify most of the ''rc.*'' startup scripts removing all the hardware related daemons, and finally replace the ''/dev'' dir.&lt;br /&gt;
&lt;br /&gt;
This is done running the script ''make_slack_vserver.sh'':&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/bash&lt;br /&gt;
#&lt;br /&gt;
# v. 2011.04.28&lt;br /&gt;
# Author: Roberto Puzzanghera&lt;br /&gt;
#&lt;br /&gt;
# This script installs a Slackware guest into a linux-vserver host (http://linux-vserver.org)&lt;br /&gt;
#&lt;br /&gt;
# Comments are welcome :-)&lt;br /&gt;
# More info here: http://notes.sagredo.eu/node/7&lt;br /&gt;
 &lt;br /&gt;
if [ $# != 1 ]; then&lt;br /&gt;
  echo &amp;quot;usage: $0 &amp;lt;server-name&amp;gt;&amp;quot;&lt;br /&gt;
  exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# adjust this to where your things live&lt;br /&gt;
NAME=$1&lt;br /&gt;
HOSTNAME=$NAME.myserver.net&lt;br /&gt;
IP=10.0.0.149&lt;br /&gt;
INTERFACE=eth0:$IP/24&lt;br /&gt;
CONTEXT=1011&lt;br /&gt;
VERSION=13.37 # Slackware version&lt;br /&gt;
 &lt;br /&gt;
# where is the vservers dir? default is /vservers&lt;br /&gt;
VDIR=&amp;quot;/vservers&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the directory where you unpacked slack_vserver.tar.gz&lt;br /&gt;
# $PWD should work, otherwise put /path/to/slack_vserver&lt;br /&gt;
SETUP=$PWD&lt;br /&gt;
 &lt;br /&gt;
# the directory where you downloaded the slackware packages&lt;br /&gt;
PACKAGES=&amp;quot;$SETUP/slackware_pkg&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
# the path to rc script file (leave as is)&lt;br /&gt;
RC=&amp;quot;$SETUP/rc&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
################### end configuration&lt;br /&gt;
 &lt;br /&gt;
# sanity check&lt;br /&gt;
 &lt;br /&gt;
if [ ! -d &amp;quot;$VDIR&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find VDIR dir: $VDIR&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1 &lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$SETUP&amp;quot; ]; then&lt;br /&gt;
        echo  &lt;br /&gt;
        echo &amp;quot;Can't find SETUP dir: $SETUP&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -d &amp;quot;$PACKAGES&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find PACKAGES dir: $PACKAGES&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
if [ ! -f &amp;quot;$RC&amp;quot; ]; then&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;Can't find RC path: $RC&amp;quot;&lt;br /&gt;
        echo &amp;quot;Exiting&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        exit 1&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
# if everything is ok start the install&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to make skeleton...&amp;quot;&lt;br /&gt;
vserver ${NAME} build -m skeleton \&lt;br /&gt;
        --hostname ${HOSTNAME} \&lt;br /&gt;
        --interface ${INTERFACE} \&lt;br /&gt;
        --context $CONTEXT \&lt;br /&gt;
        --flags lock,virt_mem,virt_uptime,virt_cpu,virt_load,sched_hard,hide_netif \&lt;br /&gt;
        --initstyle sysv&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to move the /dev folder to a temp dir the /dev folder...&amp;quot;&lt;br /&gt;
mv $VDIR/$NAME/dev $VDIR/$NAME/dev2&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to install packages...&amp;quot; &lt;br /&gt;
cd $PACKAGES&lt;br /&gt;
installpkg -root $VDIR/$NAME *.t?z; &lt;br /&gt;
echo &amp;quot;...done&amp;quot; &lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
read -p &amp;quot;press any key to copy the rc script to /etc/rc.d/init.d...&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;copying rc to /etc/rc.d/init.d/rc&amp;quot;&lt;br /&gt;
cp -p $RC $VDIR/$NAME/etc/rc.d/init.d/&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;removing x flag to rc.inet1 rc.loop and rc.sshd&amp;quot;&lt;br /&gt;
chmod -x $VDIR/$NAME/etc/rc.d/rc.inet1 $VDIR/$NAME/etc/rc.d/rc.loop $VDIR/$NAME/etc/rc.d/rc.sshd&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
echo &amp;quot;trying to adjust HOSTNAME, hosts, resolv.conf, profile. Check later...&amp;quot;&lt;br /&gt;
cp /etc/resolv.conf $VDIR/$NAME/etc/&lt;br /&gt;
cp /etc/localtime $VDIR/$NAME/etc/&lt;br /&gt;
rm $VDIR/$NAME/etc/profile&lt;br /&gt;
cp /etc/profile $VDIR/$NAME/etc/&lt;br /&gt;
echo $HOSTNAME &amp;gt;  $VDIR/$NAME/etc/HOSTNAME&lt;br /&gt;
echo &amp;quot;127.0.0.1 localhost&amp;quot; &amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
echo &amp;quot;$IP $HOSTNAME $NAME&amp;quot; &amp;gt;&amp;gt; $VDIR/$NAME/etc/hosts&lt;br /&gt;
touch $VDIR/$NAME/etc/mtab                         &lt;br /&gt;
touch $VDIR/$NAME/etc/fstab&lt;br /&gt;
echo &amp;quot;...done&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
 &lt;br /&gt;
read -p &amp;quot;press any key to restore /dev2 to /dev&amp;quot;&lt;br /&gt;
rm -r $VDIR/$NAME/dev&lt;br /&gt;
mv $VDIR/$NAME/dev2 $VDIR/$NAME/dev&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo -n &amp;quot;Do you want that I apply the patch for you y/n? [y] &amp;quot;&lt;br /&gt;
read VAR_PATCH&lt;br /&gt;
 &lt;br /&gt;
if [ &amp;quot;$VAR_PATCH&amp;quot; = 'y' ] || [ &amp;quot;$VAR_PATCH&amp;quot; = '' ]; then&lt;br /&gt;
        cd $VDIR/$NAME/etc/rc.d&lt;br /&gt;
        patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&lt;br /&gt;
        echo &amp;quot;patch applyed.&amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;You can start and enter the virtual server typing: &amp;quot;&lt;br /&gt;
        echo&lt;br /&gt;
        echo &amp;quot;vserver $NAME start&amp;quot;&lt;br /&gt;
        echo &amp;quot;vserver $NAME enter&amp;quot;&lt;br /&gt;
        else&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;DON'T FORGET to patch /etc/rc.d as follows: &amp;quot;&lt;br /&gt;
                echo&lt;br /&gt;
                echo &amp;quot;cd $VDIR/$NAME/etc/rc.d&amp;quot;&lt;br /&gt;
                echo &amp;quot;patch -p1 &amp;lt; $SETUP/linux-vserver_slackware-$VERSION.patch&amp;quot;&lt;br /&gt;
fi&lt;br /&gt;
 &lt;br /&gt;
echo&lt;br /&gt;
echo &amp;quot;More info on http://notes.sagredo.eu/node/7&amp;quot;&lt;br /&gt;
echo&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Apply the patch and start the guest ==&lt;br /&gt;
&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd /vservers/vserver_name/etc/rc.d&lt;br /&gt;
The script itsself can install the patch for you. Anyway this is how to apply the patch by yourself:patch -p1 &amp;lt; /path/to/slack_vserver/slackware-13.37.patch&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now you can start the newly created virtual server:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; start&lt;br /&gt;
vserver &amp;lt;vserver_name&amp;gt; enter&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Contact ==&lt;br /&gt;
Any comments/suggestions/questions to ''roberto dot puzzanghera at sagredo dot eu'', [http://notes.sagredo.eu]&lt;br /&gt;
&lt;br /&gt;
== Patch used ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Patch for Slackware 13.1 guest on a Linux-Vserver host&lt;br /&gt;
======================================================&lt;br /&gt;
by Roberto Puzzanghera - http://notes.sagredo.eu&lt;br /&gt;
version: 2010.12.28&lt;br /&gt;
&lt;br /&gt;
======================================================&lt;br /&gt;
&lt;br /&gt;
diff -urNB rc.d-original/rc.0 rc.d-patched/rc.0&lt;br /&gt;
--- rc.d-original/rc.0	2010-03-20 01:14:07.000000000 +0100&lt;br /&gt;
+++ rc.d-patched/rc.0	2010-12-28 17:37:41.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,18 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Bring down the networking system, but first make sure that this&lt;br /&gt;
 # isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
 if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
@@ -127,13 +99,6 @@&lt;br /&gt;
   sleep 2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
@@ -181,23 +146,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Umount any LVM volumes:&lt;br /&gt;
-if /bin/mount | /bin/grep -q '^/dev/mapper/' ; then&lt;br /&gt;
-  echo &amp;quot;Unmounting LVM volumes.&amp;quot;&lt;br /&gt;
-  /bin/umount -v $(/bin/mount | /bin/grep '^/dev/mapper/' | /bin/cut -d ' ' -f 3 | /bin/tac)&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -222,45 +170,5 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.6 rc.d-patched/rc.6&lt;br /&gt;
--- rc.d-original/rc.6	2010-03-20 01:14:07.000000000 +0100&lt;br /&gt;
+++ rc.d-patched/rc.6	2010-12-28 17:37:41.000000000 +0100&lt;br /&gt;
@@ -37,22 +37,6 @@&lt;br /&gt;
 		;;&lt;br /&gt;
 esac&lt;br /&gt;
 &lt;br /&gt;
-# Save the system time to the hardware clock using hwclock --systohc.&lt;br /&gt;
-if [ -x /sbin/hwclock ]; then&lt;br /&gt;
-  # Check for a broken motherboard RTC clock (where ioports for rtc are&lt;br /&gt;
-  # unknown) to prevent hwclock causing a hang:&lt;br /&gt;
-  if ! grep -q -w rtc /proc/ioports ; then&lt;br /&gt;
-    CLOCK_OPT=&amp;quot;--directisa&amp;quot;&lt;br /&gt;
-  fi&lt;br /&gt;
-  if grep -q &amp;quot;^UTC&amp;quot; /etc/hardwareclock 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (UTC).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock $CLOCK_OPT --utc --systohc&lt;br /&gt;
-  else&lt;br /&gt;
-    echo &amp;quot;Saving system time to the hardware clock (localtime).&amp;quot;&lt;br /&gt;
-    /sbin/hwclock  $CLOCK_OPT --localtime --systohc&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Run any local shutdown scripts:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.local_shutdown ]; then&lt;br /&gt;
   /etc/rc.d/rc.local_shutdown stop&lt;br /&gt;
@@ -98,18 +82,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.messagebus stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Try to shut down pppd:&lt;br /&gt;
-PS=&amp;quot;$(ps ax)&amp;quot;&lt;br /&gt;
-if echo &amp;quot;$PS&amp;quot; | /bin/grep -q -w pppd ; then&lt;br /&gt;
-  if [ -x /usr/sbin/ppp-off ]; then&lt;br /&gt;
-    /usr/sbin/ppp-off&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Bring down the networking system, but first make sure that this&lt;br /&gt;
 # isn't a diskless client with the / partition mounted via NFS:&lt;br /&gt;
 if ! /bin/mount | /bin/grep -q 'on / type nfs' ; then&lt;br /&gt;
@@ -127,13 +99,6 @@&lt;br /&gt;
   sleep 2&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  /bin/sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn off process accounting:&lt;br /&gt;
 if [ -x /sbin/accton -a -r /var/log/pacct ]; then&lt;br /&gt;
   /sbin/accton off&lt;br /&gt;
@@ -181,23 +146,6 @@&lt;br /&gt;
   rm -f /var/lock/subsys/*&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Turn off swap:&lt;br /&gt;
-echo &amp;quot;Turning off swap.&amp;quot;&lt;br /&gt;
-/sbin/swapoff -a&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# Umount any LVM volumes:&lt;br /&gt;
-if /bin/mount | /bin/grep -q '^/dev/mapper/' ; then&lt;br /&gt;
-  echo &amp;quot;Unmounting LVM volumes.&amp;quot;&lt;br /&gt;
-  /bin/umount -v $(/bin/mount | /bin/grep '^/dev/mapper/' | /bin/cut -d ' ' -f 3 | /bin/tac)&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Unmounting local file systems.&amp;quot;&lt;br /&gt;
-/bin/umount -v -a -t no,proc,sysfs&lt;br /&gt;
-&lt;br /&gt;
-echo &amp;quot;Remounting root filesystem read-only.&amp;quot;&lt;br /&gt;
-/bin/mount -v -n -o remount,ro /&lt;br /&gt;
-&lt;br /&gt;
 # This never hurts:&lt;br /&gt;
 /bin/sync&lt;br /&gt;
 &lt;br /&gt;
@@ -222,45 +170,5 @@&lt;br /&gt;
   done&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Deactivate LVM volume groups:&lt;br /&gt;
-if [ -r /etc/lvmtab -o -d /etc/lvm/backup ]; then&lt;br /&gt;
-  echo &amp;quot;Deactivating LVM volume groups:&amp;quot;&lt;br /&gt;
-  /sbin/vgchange -an --ignorelockingfailure&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# This never hurts again (especially since root-on-LVM always fails&lt;br /&gt;
-# to deactivate the / logical volume...  but at least it was&lt;br /&gt;
-# remounted as read-only first)&lt;br /&gt;
-/bin/sync&lt;br /&gt;
-&lt;br /&gt;
-# sleep 3 fixes problems with some hard drives that don't&lt;br /&gt;
-# otherwise finish syncing before reboot or poweroff&lt;br /&gt;
-/bin/sleep 3&lt;br /&gt;
-&lt;br /&gt;
 # This is to ensure all processes have completed on SMP machines:&lt;br /&gt;
 wait&lt;br /&gt;
-&lt;br /&gt;
-if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-  # See if this is a powerfail situation:&lt;br /&gt;
-  if /bin/egrep -q &amp;quot;FAIL|SCRAM&amp;quot; /etc/upsstatus 2&amp;gt; /dev/null ; then&lt;br /&gt;
-    # Signal UPS to shut off the inverter:&lt;br /&gt;
-    /sbin/genpowerd -k&lt;br /&gt;
-    if [ ! $? = 0 ]; then&lt;br /&gt;
-      echo&lt;br /&gt;
-      echo &amp;quot;There was an error signaling the UPS.&amp;quot;&lt;br /&gt;
-      echo &amp;quot;Perhaps you need to edit /etc/genpowerd.conf to configure&amp;quot;&lt;br /&gt;
-      echo &amp;quot;the serial line and UPS type.&amp;quot;&lt;br /&gt;
-      # Wasting 15 seconds of precious power:&lt;br /&gt;
-      /bin/sleep 15&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Now halt (poweroff with APM or ACPI enabled kernels) or reboot.&lt;br /&gt;
-if [ &amp;quot;$command&amp;quot; = &amp;quot;reboot&amp;quot; ]; then&lt;br /&gt;
-  echo &amp;quot;Rebooting.&amp;quot;&lt;br /&gt;
-  /sbin/reboot&lt;br /&gt;
-else&lt;br /&gt;
-  /sbin/poweroff&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
diff -urNB rc.d-original/rc.K rc.d-patched/rc.K&lt;br /&gt;
--- rc.d-original/rc.K	2008-12-02 21:31:48.000000000 +0100&lt;br /&gt;
+++ rc.d-patched/rc.K	2010-12-28 17:37:41.000000000 +0100&lt;br /&gt;
@@ -57,22 +57,6 @@&lt;br /&gt;
   /etc/rc.d/rc.nfsd stop&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Unmount any NFS, SMB, or CIFS filesystems:&lt;br /&gt;
-echo &amp;quot;Unmounting remote filesystems.&amp;quot;&lt;br /&gt;
-umount -a -r -t nfs,smbfs,cifs&lt;br /&gt;
-&lt;br /&gt;
-# Shut down PCMCIA devices:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ] ; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia stop&lt;br /&gt;
-  # The cards might need a little extra time here to deactivate:&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Terminate acpid before syslog:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.acpid -a -r /var/run/acpid.pid ]; then # quit&lt;br /&gt;
-  . /etc/rc.d/rc.acpid stop&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Kill all processes.&lt;br /&gt;
 echo&lt;br /&gt;
 echo &amp;quot;Sending all processes the SIGHUP signal.&amp;quot;&lt;br /&gt;
diff -urNB rc.d-original/rc.M rc.d-patched/rc.M&lt;br /&gt;
--- rc.d-original/rc.M	2010-02-07 04:01:28.000000000 +0100&lt;br /&gt;
+++ rc.d-patched/rc.M	2010-12-28 17:37:41.000000000 +0100&lt;br /&gt;
@@ -20,10 +20,6 @@&lt;br /&gt;
   /sbin/ldconfig &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Screen blanks after 15 minutes idle time, and powers down in one hour&lt;br /&gt;
-# if the kernel supports APM or ACPI power management:&lt;br /&gt;
-/bin/setterm -blank 15 -powersave powerdown -powerdown 60&lt;br /&gt;
-&lt;br /&gt;
 # Set the hostname.&lt;br /&gt;
 if [ -r /etc/HOSTNAME ]; then&lt;br /&gt;
   /bin/hostname $(cat /etc/HOSTNAME | cut -f1 -d .)&lt;br /&gt;
@@ -36,31 +32,6 @@&lt;br /&gt;
 # Save the contents of 'dmesg':&lt;br /&gt;
 /bin/dmesg -s 65536 &amp;gt; /var/log/dmesg&lt;br /&gt;
 &lt;br /&gt;
-# Initialize PCMCIA devices:&lt;br /&gt;
-#&lt;br /&gt;
-# NOTE: This used to be started near the top of rc.S so that PCMCIA devices&lt;br /&gt;
-# could be fsck'ed along with the other drives.  This had some unfortunate&lt;br /&gt;
-# side effects, however, since root isn't yet read-write, and /var might not&lt;br /&gt;
-# even be mounted the .pid files can't be correctly written in /var/run and&lt;br /&gt;
-# the pcmcia system can't be correctly shut down.  If you want some PCMCIA&lt;br /&gt;
-# partition to be mounted at boot (or when the card is inserted) then add&lt;br /&gt;
-# the appropriate lines to /etc/pcmcia/scsi.opts.&lt;br /&gt;
-#&lt;br /&gt;
-# Note that the stuff in /etc/pcmcia/ is only for 2.4.x kernels using&lt;br /&gt;
-# 16-bit PCMCIA cards (not 32-bit Cardbus cards!).  For example, with a&lt;br /&gt;
-# wireless card you might need to set options in /etc/pcmcia OR in&lt;br /&gt;
-# /etc/rc.d/rc.wireless.conf, or even in /etc/rc.d/rc.inet1.conf (with&lt;br /&gt;
-# extra options if needed for the encryption key, ESSID, etc.)&lt;br /&gt;
-#&lt;br /&gt;
-# Hopefully this situation will be unified in the future, but for now&lt;br /&gt;
-# that's how it is...&lt;br /&gt;
-#&lt;br /&gt;
-if [ -x /etc/rc.d/rc.pcmcia ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.pcmcia start&lt;br /&gt;
-  # The cards might need a little extra time here to initialize.&lt;br /&gt;
-  sleep 5&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start the system logger.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.syslog -a -x /usr/sbin/syslogd -a -d /var/log ]; then&lt;br /&gt;
   . /etc/rc.d/rc.syslog start&lt;br /&gt;
@@ -72,26 +43,11 @@&lt;br /&gt;
   /usr/bin/fc-cache -f &amp;amp;&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# If we are returning from single-user mode we will need to restart&lt;br /&gt;
-# udevd on systems that use udev:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems ; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /etc/rc.d/rc.udev start&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Initialize the networking hardware.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet1 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet1&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Look for additional USB/SCSI/IEEE1394/etc devices on multiple LUNs:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.scanluns ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.scanluns&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start networking daemons:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.inet2 ]; then&lt;br /&gt;
   . /etc/rc.d/rc.inet2&lt;br /&gt;
@@ -118,17 +74,6 @@&lt;br /&gt;
 chmod 755 / 2&amp;gt; /dev/null&lt;br /&gt;
 chmod 1777 /tmp /var/tmp&lt;br /&gt;
 &lt;br /&gt;
-# Start APM or ACPI daemon.&lt;br /&gt;
-# If APM is enabled in the kernel, start apmd:&lt;br /&gt;
-if [ -e /proc/apm ]; then&lt;br /&gt;
-  if [ -x /usr/sbin/apmd ]; then&lt;br /&gt;
-    echo &amp;quot;Starting APM daemon:  /usr/sbin/apmd&amp;quot;&lt;br /&gt;
-    /usr/sbin/apmd&lt;br /&gt;
-  fi&lt;br /&gt;
-elif [ -x /etc/rc.d/rc.acpid ]; then # otherwise, start acpid:&lt;br /&gt;
-  . /etc/rc.d/rc.acpid start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Update any existing icon cache files:&lt;br /&gt;
 if find /usr/share/icons 2&amp;gt; /dev/null | grep -q icon-theme.cache ; then&lt;br /&gt;
   for theme_dir in /usr/share/icons/* ; do&lt;br /&gt;
@@ -161,11 +106,6 @@&lt;br /&gt;
   sh /etc/rc.d/rc.hald start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start Bluetooth:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.bluetooth ]; then&lt;br /&gt;
-  sh /etc/rc.d/rc.bluetooth start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Start wicd:&lt;br /&gt;
 if [ -x /etc/rc.d/rc.wicd ]; then&lt;br /&gt;
   sh /etc/rc.d/rc.wicd start&lt;br /&gt;
@@ -207,36 +147,6 @@&lt;br /&gt;
   /etc/rc.d/rc.atalk&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start smartd, which monitors the status of S.M.A.R.T. compatible&lt;br /&gt;
-# hard drives and reports any problems.  Note some devices (which aren't&lt;br /&gt;
-# smart, I guess ;) will hang if probed by smartd, so it's commented out&lt;br /&gt;
-# by default.&lt;br /&gt;
-#if [ -x /usr/sbin/smartd ]; then&lt;br /&gt;
-#  /usr/sbin/smartd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
-# If we're using udev, make /dev/cdrom and any other optical drive symlinks&lt;br /&gt;
-# if some udev rule hasn't made them already:&lt;br /&gt;
-if grep -wq sysfs /proc/mounts &amp;amp;&amp;amp; grep -q tmpfs /proc/filesystems; then&lt;br /&gt;
-  if ! grep -wq nohotplug /proc/cmdline ; then&lt;br /&gt;
-    if [ -x /lib/udev/rc.optical-symlinks -a -x /etc/rc.d/rc.udev ]; then&lt;br /&gt;
-      /bin/sh /lib/udev/rc.optical-symlinks&lt;br /&gt;
-    fi&lt;br /&gt;
-  fi&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
-# Monitor the UPS with genpowerd.&lt;br /&gt;
-# To use this, uncomment this section and edit your settings in&lt;br /&gt;
-# /etc/genpowerd.conf (serial device, UPS type, etc).  For more information,&lt;br /&gt;
-# see &amp;quot;man genpowerd&amp;quot; or the extensive documentation in the&lt;br /&gt;
-# /usr/doc/genpower-*/ directory.&lt;br /&gt;
-# You'll also need to configure a similar block in /etc/rc.d/rc.6 if you want&lt;br /&gt;
-# support for stopping the UPS's inverter after the machine halts.&lt;br /&gt;
-#if [ -x /sbin/genpowerd ]; then&lt;br /&gt;
-#  echo &amp;quot;Starting genpowerd daemon...&amp;quot;&lt;br /&gt;
-#  /sbin/genpowerd&lt;br /&gt;
-#fi&lt;br /&gt;
-&lt;br /&gt;
 # Turn on process accounting.  To enable process accounting, make sure the&lt;br /&gt;
 # option for BSD process accounting is enabled in your kernel, and then&lt;br /&gt;
 # create the file /var/log/pacct (touch /var/log/pacct).  By default, process&lt;br /&gt;
@@ -301,11 +211,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.sendmail start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Load ALSA (sound) defaults:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.alsa ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.alsa&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # Load a custom screen font if the user has an rc.font script.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.font ]; then&lt;br /&gt;
   . /etc/rc.d/rc.font&lt;br /&gt;
@@ -337,11 +242,6 @@&lt;br /&gt;
   . /etc/rc.d/rc.samba start&lt;br /&gt;
 fi&lt;br /&gt;
 &lt;br /&gt;
-# Start the GPM mouse server:&lt;br /&gt;
-if [ -x /etc/rc.d/rc.gpm ]; then&lt;br /&gt;
-  . /etc/rc.d/rc.gpm start&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If there are SystemV init scripts for this runlevel, run them.&lt;br /&gt;
 if [ -x /etc/rc.d/rc.sysvinit ]; then&lt;br /&gt;
   . /etc/rc.d/rc.sysvinit&lt;br /&gt;
diff -urNB rc.d-original/rc.inet2 rc.d-patched/rc.inet2&lt;br /&gt;
--- rc.d-original/rc.inet2	2007-09-18 00:07:32.000000000 +0200&lt;br /&gt;
+++ rc.d-patched/rc.inet2	2010-12-28 17:37:41.000000000 +0100&lt;br /&gt;
@@ -15,27 +15,6 @@&lt;br /&gt;
 &lt;br /&gt;
 # At this point, we are ready to talk to The World...&lt;br /&gt;
 &lt;br /&gt;
-&lt;br /&gt;
-# Mount remote (NFS) filesystems:&lt;br /&gt;
-if cat /etc/fstab | grep -v '^#' | grep -w nfs 1&amp;gt; /dev/null 2&amp;gt; /dev/null ; then&lt;br /&gt;
-  # Start rpc.portmap, /sbin/rpc.lockd, and /sbin/rpc.statd if we find NFS&lt;br /&gt;
-  # volumes defined in /etc/fstab since these will need to be running in order&lt;br /&gt;
-  # to mount them.  If they are not running, attempting to mount an NFS&lt;br /&gt;
-  # partition will cause mount to hang, or at least result in unreliable&lt;br /&gt;
-  # operation.  Keep this in mind if you plan to mount unlisted NFS&lt;br /&gt;
-  # partitions... &lt;br /&gt;
-  # If you have uncommented NFS partitions in your /etc/fstab, rc.rpc is run&lt;br /&gt;
-  # whether it is set as executable or not.  If you don't want to run it,&lt;br /&gt;
-  # comment the NFS partitions out in /etc/fstab or erase/rename rc.rpc.&lt;br /&gt;
-  if [ -r /etc/rc.d/rc.rpc ]; then&lt;br /&gt;
-    sh /etc/rc.d/rc.rpc start&lt;br /&gt;
-  fi&lt;br /&gt;
-  echo &amp;quot;Mounting remote (NFS) file systems:  /sbin/mount -a -t nfs&amp;quot;&lt;br /&gt;
-  /sbin/mount -a -t nfs          # This may be our /usr runtime!&lt;br /&gt;
-  # Show the mounted volumes:&lt;br /&gt;
-  /sbin/mount -v -t nfs&lt;br /&gt;
-fi&lt;br /&gt;
-&lt;br /&gt;
 # If /etc/rc.d/rc.rpc is executable, run it to load rpc.portmap, rpc.lockd,&lt;br /&gt;
 # and rpc.statd.  This might be needed to mount NFS partitions that are not&lt;br /&gt;
 # listed in /etc/fstab.  Starting this twice won't hurt as the script will&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Slackware package list ==&lt;br /&gt;
Here is the content of the file [http://notes.sagredo.eu/sites/notes.sagredo.eu/files/linux-vserver/PKG_LIST PKG_LIST]&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# v. 2011.01.07&lt;br /&gt;
# some commented pkg to avoid duplicates (man will download both man and man-pages)&lt;br /&gt;
&lt;br /&gt;
#[A]&lt;br /&gt;
a/aaa_base&lt;br /&gt;
a/aaa_elflibs&lt;br /&gt;
a/aaa_terminfo&lt;br /&gt;
a/acl&lt;br /&gt;
a/attr&lt;br /&gt;
a/bash&lt;br /&gt;
a/bin&lt;br /&gt;
a/bzip2&lt;br /&gt;
a/coreutils&lt;br /&gt;
a/cpio&lt;br /&gt;
a/cxxlibs&lt;br /&gt;
a/dcron&lt;br /&gt;
a/dialog&lt;br /&gt;
a/etc&lt;br /&gt;
a/file&lt;br /&gt;
a/findutils&lt;br /&gt;
a/gawk&lt;br /&gt;
a/gettext&lt;br /&gt;
a/glibc-solibs&lt;br /&gt;
a/glibc-zoneinfo&lt;br /&gt;
a/grep&lt;br /&gt;
a/gzip&lt;br /&gt;
a/infozip&lt;br /&gt;
a/kbd&lt;br /&gt;
a/less&lt;br /&gt;
a/logrotate&lt;br /&gt;
a/openssl-solibs&lt;br /&gt;
a/patch&lt;br /&gt;
a/pkgtools&lt;br /&gt;
a/procps&lt;br /&gt;
a/quota&lt;br /&gt;
a/sed&lt;br /&gt;
a/shadow&lt;br /&gt;
a/slocate&lt;br /&gt;
a/sysklogd&lt;br /&gt;
a/sysvinit&lt;br /&gt;
# a/sysvinit-functions&lt;br /&gt;
# a/sysvinit-scripts&lt;br /&gt;
a/tar&lt;br /&gt;
a/time&lt;br /&gt;
a/tree&lt;br /&gt;
a/utempter&lt;br /&gt;
a/util-linux&lt;br /&gt;
a/xz&lt;br /&gt;
a/which&lt;br /&gt;
&lt;br /&gt;
#[AP]&lt;br /&gt;
ap/at&lt;br /&gt;
ap/diffutils&lt;br /&gt;
ap/groff&lt;br /&gt;
ap/lsof&lt;br /&gt;
ap/man&lt;br /&gt;
# ap/man-pages&lt;br /&gt;
ap/most&lt;br /&gt;
ap/nano&lt;br /&gt;
ap/sudo&lt;br /&gt;
ap/vim&lt;br /&gt;
 &lt;br /&gt;
#[D]&lt;br /&gt;
d/autoconf&lt;br /&gt;
d/automake&lt;br /&gt;
d/binutils&lt;br /&gt;
d/bison&lt;br /&gt;
d/flex&lt;br /&gt;
d/gcc-4&lt;br /&gt;
d/gcc-g++&lt;br /&gt;
d/gettext-tools&lt;br /&gt;
d/kernel-headers&lt;br /&gt;
d/libtool&lt;br /&gt;
d/m4&lt;br /&gt;
d/make&lt;br /&gt;
d/perl&lt;br /&gt;
d/pkg-config&lt;br /&gt;
 &lt;br /&gt;
#[L]&lt;br /&gt;
l/apr&lt;br /&gt;
l/db42&lt;br /&gt;
l/db44&lt;br /&gt;
l/freetype&lt;br /&gt;
l/gd-&lt;br /&gt;
l/gdbm&lt;br /&gt;
l/glibc&lt;br /&gt;
# l/glibc-i18n&lt;br /&gt;
l/libjpeg&lt;br /&gt;
l/libmcrypt&lt;br /&gt;
l/libpng&lt;br /&gt;
l/lzo&lt;br /&gt;
l/mpfr&lt;br /&gt;
l/ncurses&lt;br /&gt;
l/pcre&lt;br /&gt;
l/popt&lt;br /&gt;
l/readline&lt;br /&gt;
l/v4l-utils&lt;br /&gt;
l/libxslt&lt;br /&gt;
l/t1lib&lt;br /&gt;
l/zlib&lt;br /&gt;
 &lt;br /&gt;
#[N]&lt;br /&gt;
n/cyrus-sasl&lt;br /&gt;
n/inetd&lt;br /&gt;
n/iproute2&lt;br /&gt;
n/iputils&lt;br /&gt;
n/libgcrypt&lt;br /&gt;
n/mtr&lt;br /&gt;
n/net-tools&lt;br /&gt;
n/netwatch&lt;br /&gt;
n/network-scripts&lt;br /&gt;
n/ntp&lt;br /&gt;
n/openssh&lt;br /&gt;
n/openssl&lt;br /&gt;
n/tcp_wrappers&lt;br /&gt;
n/telnet&lt;br /&gt;
n/traceroute&lt;br /&gt;
n/wget&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Roberto.puzzanghera</name></author>	</entry>

	</feed>