Difference between revisions of "Hd Install Without a Monitor HowTo"


From Knoppix Documentation Wiki
Jump to: navigation, search
 
Line 1: Line 1:
=== Warning, this is only for people, which knows how to play with GNU/Linx! ===
+
'''Warning, this is only for people, who know how to play with GNU/Linux!'''
  
 
If you have no (or no free) monitor to install a new GNU/Linux server/firewall... but you have a laptop (or a PC with a monitor) - run knx-hdinstall unblind ;)
 
If you have no (or no free) monitor to install a new GNU/Linux server/firewall... but you have a laptop (or a PC with a monitor) - run knx-hdinstall unblind ;)
Line 10: Line 10:
 
Ctrl-C and type it again.
 
Ctrl-C and type it again.
  
 +
'''Switch to one root shell with'''
 +
Alt-Ctrl-F2
  
==== Switch to one root shell with ====
+
'''Change the rootpassword and remember to type it twice(!)'''
alt-ctr-F2
+
blind@blackbox#passwd root
 +
test
 +
test
  
==== Change the rootpassword and remember to type it twice(!) ====
+
'''Setup the network, for example:'''
blind@blackbox#passwd root return<br>
+
blind@blackbox# ifconfig eth0 192.168.0.5 netmask 255.255.255.0 up
test return<br>
+
blind@blackbox# route add default gw 192.168.0.3 eth0
test return<br>
+
  
==== Setup the network, for example: ====
+
'''Knoppix has an active firewall, stop it:'''
blind@blackbox# ifconfig eth0 192.168.0.5 netmask 255.255.255.0 up return<br>
+
blind@blackbox# rm /etc/hosts.deny
blind@blackbox# route add default gw 192.168.0.3 eth0 return<br>
+
blind@blackbox# rm /etc/hosts.allow
 +
blind@blackbox# /etc/init.d/inetd restart
  
==== Knoppix has an active firewall, stop it: ====
+
'''Warning - I can't explain how to make your system safe - hope that somebody will add this ;)'''
blind@blackbox# rm /etc/hosts.deny return<br>
+
'''Start ssh:'''
blind@blackbox# rm /etc/hosts.allow return<br>
+
blind@blackbox# /etc/init.d/ssh start
blind@blackbox# /etc/init.d/inetd restart return<br>
+
  
 +
'''Now go to your Laptop and when you can ping'''
 +
user@laptop# ping 192.168.0.5
  
=== Warning - I can't explain how to make your system safe - hope that sombody will add this ;) ===
+
'''When your network is ok, then start a ssh connection:'''
 
+
  user@laptop# ssh root@192.168.0.5
==== Start ssh: ====
+
blind@blackbox# /etc/init.d/ssh start return
+
 
+
 
+
 
+
==== Now go to your Laptop and when you can ping ====
+
user@laptop# ping 192.168.0.5 return
+
 
+
==== than your network is ok, then start a ssh connection: ====
+
user@laptop# ssh root@192.168.0.5
+
  
 
(if you got problems it is likely that your laptop has
 
(if you got problems it is likely that your laptop has
 
an active firewall.)
 
an active firewall.)
  
==== Via the ssh conection you can now start a VNC connection on your blackbox: ====
+
'''Via the ssh conection you can now start a VNC connection on your blackbox:'''
root@0[[/]]vncserver<br>
+
root@0[[/]]vncserver
root@0[[/]]vncviewer localhost:1
+
root@0[[/]]vncviewer localhost:1
 
+
==== Now you can follow [[Hd InstallHowTo]] ;) ====
+
  
 +
'''Now you can follow [[Hd Install HowTo]] ;)'''
  
 
After the Knoppix HD-install update your Debian(unstable). When you laptop has two networkcards, an internetconnection and I hope a firewall, you can use it as router/firewall for secure your blackbox during you update it. Be root on your laptop:
 
After the Knoppix HD-install update your Debian(unstable). When you laptop has two networkcards, an internetconnection and I hope a firewall, you can use it as router/firewall for secure your blackbox during you update it. Be root on your laptop:
  
root@laptop# modprobe iptable_nat<br>
+
root@laptop# modprobe iptable_nat<br>
root@laptop# iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE<br>
+
root@laptop# iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE<br>
root@laptop# echo 1 > /proc/sys/net/ipv4/ip_forward
+
root@laptop# echo 1 > /proc/sys/net/ipv4/ip_forward
  
 +
'''Using a KVM switch:'''
 +
A [[http://en.wikipedia.org/wiki/KVM_switch KVM switch]] is a fairly simple apparatus to which you connect cables from your monitor, keyboard, mouse and sometimes loudspeakers and USB which then connects to two or more computers.
 +
Switching between computers varies between manufacturers, with some you double-tap Scroll Lock.
  
==== You are welcome to make this [[How To]] better! ====
+
'''You are welcome to make this How To better!'''

Revision as of 21:21, 26 December 2004

Warning, this is only for people, who know how to play with GNU/Linux!

If you have no (or no free) monitor to install a new GNU/Linux server/firewall... but you have a laptop (or a PC with a monitor) - run knx-hdinstall unblind ;)

You can use Headless Knoppix and run a script to be able to use ssh, or connect a keyboard and type the first commands blind 
Connect on of the blackbox's netadapter with your Laptop by a cross-link cable or via a hub/switch. Put in the Knoppix CD and hope that the BIOS is set to CD-Boot first.


When now Knoppix is booted - you know after loading the bootloader you can use cheatcodes, type blind "knoppix 2" and return and Knoppix will boot. From now on, everytime you may make a typo, don't correct it, use Ctrl-C and type it again.

Switch to one root shell with

Alt-Ctrl-F2

Change the rootpassword and remember to type it twice(!)

blind@blackbox#passwd root
test
test

Setup the network, for example:

blind@blackbox# ifconfig eth0 192.168.0.5 netmask 255.255.255.0 up
blind@blackbox# route add default gw 192.168.0.3 eth0

Knoppix has an active firewall, stop it:

blind@blackbox# rm /etc/hosts.deny
blind@blackbox# rm /etc/hosts.allow
blind@blackbox# /etc/init.d/inetd restart

Warning - I can't explain how to make your system safe - hope that somebody will add this ;) Start ssh:

blind@blackbox# /etc/init.d/ssh start

Now go to your Laptop and when you can ping

user@laptop# ping 192.168.0.5

When your network is ok, then start a ssh connection:

 user@laptop# ssh root@192.168.0.5

(if you got problems it is likely that your laptop has an active firewall.)

Via the ssh conection you can now start a VNC connection on your blackbox:

root@0/vncserver
root@0/vncviewer localhost:1

Now you can follow Hd Install HowTo ;)

After the Knoppix HD-install update your Debian(unstable). When you laptop has two networkcards, an internetconnection and I hope a firewall, you can use it as router/firewall for secure your blackbox during you update it. Be root on your laptop:

root@laptop# modprobe iptable_nat
root@laptop# iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
root@laptop# echo 1 > /proc/sys/net/ipv4/ip_forward

Using a KVM switch: A [KVM switch] is a fairly simple apparatus to which you connect cables from your monitor, keyboard, mouse and sometimes loudspeakers and USB which then connects to two or more computers. Switching between computers varies between manufacturers, with some you double-tap Scroll Lock.

You are welcome to make this How To better!