User Tools

Site Tools


vps_-_debian

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
vps_-_debian [2021/04/02 09:12] – [rsyslogd] hc9vps_-_debian [2021/04/02 18:51] (current) – [Networking] hc9
Line 40: Line 40:
 //Note: For VPS installations of Debian 8.4 (jesse) on VPS3, please omit the above dns-nameservers line from the interfaces file, and instead add this line to //**/etc/resolv.conf**: //Note: For VPS installations of Debian 8.4 (jesse) on VPS3, please omit the above dns-nameservers line from the interfaces file, and instead add this line to //**/etc/resolv.conf**:
  
-  nameserver 205.166.94.20+<file config /etc/resolv.conf> 
 +nameserver 205.166.94.20 
 +</file>
  
 Add this to /etc/hosts: Add this to /etc/hosts:
Line 128: Line 130:
 Load rules (now): Load rules (now):
  
-  # iptables -F +<file config now> 
-  # iptables-restore < /etc/firewall+# iptables -F 
 +# iptables-restore < /etc/firewall 
 +</file>
  
 Load rules (boot): Load rules (boot):
  
-  # vi /etc/network/if-pre-up.d/firewall+<file config boot> 
 +# vi /etc/network/if-pre-up.d/firewall
  
-  #!/bin/sh +#!/bin/sh 
-  /sbin/iptables-restore < /etc/firewall+/sbin/iptables-restore < /etc/firewall 
 + 
 +# chmod 755 /etc/network/if-pre-up.d/firewall 
 +</file>
  
-  # chmod 755 /etc/network/if-pre-up.d/firewall 
  
 ===== Software and Distribution Updating ===== ===== Software and Distribution Updating =====
Line 144: Line 151:
 To update your system, run the following commands: To update your system, run the following commands:
  
-  * apt-get update +  * apt-get update <code> apt-get update 
-  * apt-get dist-upgrade -y+</code> 
 +  * apt-get dist-upgrade -y <code> apt-get dist-upgrade -y 
 +</code>
  
 ===== Reducing Memory Usage ===== ===== Reducing Memory Usage =====
Line 155: Line 164:
 You might not need one or both of those, so you can deactivate them with You might not need one or both of those, so you can deactivate them with
  
 +<file config cron and at>
   # update-rc.d -f atd remove   # update-rc.d -f atd remove
   # update-rc.d -f cron remove   # update-rc.d -f cron remove
 +</file>
  
 This frees up ca. 7MB (if both are deactivated). This frees up ca. 7MB (if both are deactivated).
Line 164: Line 175:
 This being a virtual system, you won't need getty on tty1-6. In order to eliminate them, edit /etc/inittab and modify the corresponding lines like this: This being a virtual system, you won't need getty on tty1-6. In order to eliminate them, edit /etc/inittab and modify the corresponding lines like this:
  
-<code>+<file config /etc/inittab>
   co:2345:respawn:/sbin/getty hvc0 9600 linux   co:2345:respawn:/sbin/getty hvc0 9600 linux
  
Line 173: Line 184:
   #5:23:respawn:/sbin/getty 38400 tty5   #5:23:respawn:/sbin/getty 38400 tty5
   #6:23:respawn:/sbin/getty 38400 tty6   #6:23:respawn:/sbin/getty 38400 tty6
-</code>+</file>
  
 You need to keep the line with hvc0 so you can attach a serial console from vps.sdf.org to your vps. This frees up ca. 10MB. You need to keep the line with hvc0 so you can attach a serial console from vps.sdf.org to your vps. This frees up ca. 10MB.
Line 181: Line 192:
 rsyslogd eats a lot of memory by default (26MB on my vps) which can be reduced by the usage of ulimit. Edit /etc/init.d/rsyslog and include the following line just before the command where rsyslogd will be started: rsyslogd eats a lot of memory by default (26MB on my vps) which can be reduced by the usage of ulimit. Edit /etc/init.d/rsyslog and include the following line just before the command where rsyslogd will be started:
  
-  ulimit -s 256+<file config /etc/init.d/rsyslog> 
 +ulimit -s 256 
 +</file>
  
 Example: Example:
Line 253: Line 266:
  
 ---- ----
-$Id: VPS_Debian.html,v 1.19 2018/02/22 02:06:34 slugmax Exp $+$Id: VPS_Debian.html,v 1.19 2018/02/22 02:06:34 slugmax Exp $ [[http://sdf.org/?tutorials/VPS_Debian|Debian on SDF VPS]] - traditional link (using [[wp>Revision_Control_System|RCS]]) 
  
vps_-_debian.1617354759.txt.gz · Last modified: 2021/04/02 09:12 by hc9