Ja. Een systeem kan sowieso starten zonder al die rommel.
Als je ssh installeert (apt-get install ssh openssh-server) kan je op afstand inloggen en onderhoud doen.
Daarbij is het wel handig als je je server een vast IP adres geeft, anders is het zo'n gezoek....
Hier een overzicht van hoe ik het gedaan heb. Het zal zeker anders, beter en makkelijker kunnen maar dit werkt prima voor me:
FTP Server Setup - Ubuntu 6.06 LTS Server (Dapper Drake)
---------------------------------------------------------------------
Maak bij het installeren een aparte ext3 partitie aan met aanhechtpunt /backup
Na het installeren van de server software deze wel aan een toetsenbord en beeldscherm hangen!!!
sudo passwd root
su
apt-get install ssh openssh-server
Met ifconfig -a kan je nu het IP adres van je server zien, en als je PuTTY op je XP machine installeert kan je vanaf dit moment vanaf je XP machine op je server inloggen. Keyboard en toetsenbord heb je nu dus niet meer nodig.
update-alternatives --config editor (verander naar vim, dit is mijn voorkeur maar nano werkt ook prima)
rm /etc/network/interfaces
vi /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
auto eth0
iface eth0 inet static
address 192.168.2.[nummer voor het vaste adres]
netmask 255.255.255.0
network 192.168.2.0
broadcast 192.168.2.255
gateway 192.168.2.1
Pas 192.168.2.* even aan aan de IP range van je eigen netwerk, wordt bepaald door je DHCP server (vaak het (ADSL) modem)
Fix apt:
---------
rm /etc/apt/sources.list
vi /etc/apt/sources.list
# Automatically generated sources.list
#
http://www.ubuntulinux.nl/source-o-matic#
# If you get errors about missing keys, lookup the key in this file
# and run these commands (replace KEY with the key number)
#
# gpg --keyserver subkeys.pgp.net --recv KEY
# gpg --export --armor KEY | sudo apt-key add -
# Ubuntu supported packages (packages, GPG key: 437D05B5)
deb
http://nl.archive.ubuntu.com/ubuntu dapper main restricted
deb
http://nl.archive.ubuntu.com/ubuntu dapper-updates main restricted
deb
http://security.ubuntu.com/ubuntu dapper-security main restricted
# Ubuntu supported packages (sources, GPG key: 437D05B5)
deb-src
http://nl.archive.ubuntu.com/ubuntu dapper main restricted
deb-src
http://nl.archive.ubuntu.com/ubuntu dapper-updates main restricted
deb-src
http://security.ubuntu.com/ubuntu dapper-security main restricted
# Ubuntu community supported packages (packages, GPG key: 437D05B5)
deb
http://nl.archive.ubuntu.com/ubuntu dapper universe multiverse
deb
http://nl.archive.ubuntu.com/ubuntu dapper-updates universe multiverse
deb
http://security.ubuntu.com/ubuntu dapper-security universe multiverse
# Ubuntu community supported packages (sources, GPG key: 437D05B5)
deb-src
http://nl.archive.ubuntu.com/ubuntu dapper universe multiverse
deb-src
http://nl.archive.ubuntu.com/ubuntu dapper-updates universe multiverse
deb-src
http://security.ubuntu.com/ubuntu dapper-security universe multiverse
apt-get update; apt-get upgrade
Synchronize time:
---------------------
apt-get install ntp ntpdate
Automatische updates:
--------------------------
touch /etc/cron.weekly/apt-security-updates
vi /etc/cron.weekly/apt-security-updates
#! /bin/sh
echo "**************" >> /var/log/apt-security-updates
date >> /var/log/apt-security-updates
apt-get update >> /var/log/apt-security-updates
apt-get upgrade -y -t dapper-security >> /var/log/apt-security-updates
echo "Security updates installed (if found)"
chmod 755 /etc/cron.weekly/apt-security-updates
SSH:
------
vi /etc/ssh/sshd_config
LoginGraceTime 30
PermitRootLogin no
/etc/init.d/ssh restart
Je kan nu niet meer direct als root inloggen via PuTTY maar nog wel via su root worden nadat je met een andere gebruiker ingelogd bent.
Backup:
---------
mkdir /backup/[machinenaam] /backup/[machinenaam]/monthly /backup/[machinenaam]/last-full
touch /backup/[machinenaam]/last-full/[machinenaam]-full-date
vi /backup/[machinenaam]/last-full/[machinenaam]-full-date
dd-Mmm (dus bijv. 23-Nov)
chmod 775 /backup/[machinenaam]/last-full/[machinenaam]-full-date
touch /etc/cron.daily/backup.cron
vi /etc/cron.daily/backup.cron
#!/bin/sh
# full and incremental backup script
# created 07 February 2000
# Based on a script by Daniel O'Callaghan
# and modified by Gerhard Mourani
# Adjust date format for your locale
export LOCALE=C
export LC_ALL=C
# Change the 5 variables below to fit your computer/backup
BACKUP=[machinenaam] # name of the backup
DIRECTORIES="/etc /home /root /usr /var" # directories to backup
BACKUPDIR=/backup/[machinenaam] # where to store the backups
TIMEDIR=/backup/[machinenaam]/last-full # where to store time of full backup
TAR=/bin/tar # name and location of tar
# You should not have to change anything below here
PATH=/usr/local/bin:/usr/bin:/bin
DOW=`date +%a` # Day of the week e.g. Mon
DOM=`date +%d` # Date of the Month e.g. 27
DM=`date +%d%b` # Date and Month e.g. 27Sep
# On the 1st of the month a permanent full backup is made
# Every Sunday a full backup is made - overwriting last Sunday's backup
# The rest of the time an incremental backup is made. Each incremental
# backup overwrites last week's incremental backup of the same name.
#
# if NEWER = "", then tar backs up all files in the directories
# otherwise it backs up files newer than the NEWER date. NEWER
# gets it date from the file written every Sunday.
# Monthly full backup
if [ $DOM = "01" ]; then
NEWER=""
$TAR $NEWER -cf $BACKUPDIR/monthly/$BACKUP-$DM.tar $DIRECTORIES
echo "Maandelijkse volledige backup $BACKUP $DM" >> /var/log/script.log
fi
# Weekly full backup
if [ $DOW = "Sun" ]; then
NEWER=""
NOW=`date +%d-%b`
# Update full backup date
echo $NOW > $TIMEDIR/$BACKUP-full-date
$TAR $NEWER -cf $BACKUPDIR/$DOW-$BACKUP.tar $DIRECTORIES
echo "Wekelijkse volledige backup $BACKUP $DM" >> /var/log/script.log
# Make incremental backup - overwrite last weeks
else
# Get date of last full backup
NEWER="--newer `cat $TIMEDIR/$BACKUP-full-date`"
$TAR $NEWER -cf $BACKUPDIR/$DOW-$BACKUP.tar $DIRECTORIES
echo "Dagelijkse incrementele backup $BACKUP $DM" >> /var/log/script.log
fi
chmod 755 /etc/cron.daily/backup.cron
crontab -e
00 01 * * * /etc/cron.daily/backup.cron &> /dev/null
ProFTP
------
apt-get install proftpd proftpd-common
vi /etc/proftpd.conf
# Adding additional security
DefaultRoot ~
IdentLookups off
ServerIdent on "FTP Server ready."
/etc/init.d/proftpd restart
adduser --home /backup/[backup account]
Als je nu de backup software van Comodo op je XP box zet, kan je de backup automatisch via FTP naar je server laten lopen.
Succes!