It would help me if you'd expand this more.I'm trying to make a customized version of KNOPPIX 6.2 that should run totally in RAM.
An obvious question is: have you considered the 'toram' cheatcode?
Hello to everyone,
I'm trying to make a customized version of KNOPPIX 6.2 that should run totally in RAM.
The customizations I need to do are very few :
1) automount in write mode the first two NTFS/FAT32 partitions of the first hard disk
2) mount the CD/ROM after the default user (knoppix) or (root ?) is logged on
3) start automatically a session of DOSEMU after that the knoppix user is logged on
This is what I did while I was in chroot :
apt-get install dosemu
cd /mnt
mkdir cdrom
mkdir hda1
mkdir hda2
mkdir sda1
mkdir sda2
cd /home/knoppix/.dosemu/drives/c
nano autoexec.bat
lredir e: linux\fs/mnt/cdrom c
lredir f: linux\fs/mnt/hda1
lredir g: linux\fs/mnt/hda2
lredir h: linux\fs/mnt/sda1
lredir i: linux\fs/mnt/sda2
nano /home/knoppix/.bash_profile
#!/bin/sh
clear
read -p "Insert your Windows installation disk and press a key to continue" disco
sudo mount -t auto /dev/cdrom /mnt/cdrom
dosemu
mv /etc/skel /etc/skel-old
mv /home/knoppix /etc/skel
chown root:root -R /etc/skel
cp -Rp /etc/skel /home/knoppix
chown knoppix:knoppix -R /home/knoppix
When Knoppix starts the script I put in /home/knoppix/.bash_profile is not executed. Why ?
The folder /home/knoppix is empty. Instead,I have everything on /etc/skel/,like the .dosemu folder and the .bash_profile script. I would like that it is placed on /home/knoppix and that it is executed when the knoppix starts. Thanks.
It would help me if you'd expand this more.I'm trying to make a customized version of KNOPPIX 6.2 that should run totally in RAM.
An obvious question is: have you considered the 'toram' cheatcode?
Yes,I will use this option,but the problem now is that I don't know how to start automatically the script inside .bash_profile when the Knoppix has been loaded in Ram
You can start any program at the end of the boot process
via a script in /etc/rc.local.
Does that help?
/etc/rc.local
SERVICES="cups"
for i in $SERVICES; do
[ -x /etc/init.d/"$i" ] && /etc/init.d/"$i" start >/dev/null 2>&1
done
/etc/skel/script.sh
exit o
/etc/skel/script.sh
#!/bin/sh
clear
read -p "Insert your Windows installation disk and press a key to continue" disco
sudo mount -t auto /dev/cdrom /mnt/cdrom
dosemu
is this right ?
I don't know what you want to achieve.
I wonder if you meant exit 0 as in exit zero, not o.
Try it and find out.
For openers, /etc/rc.local is directory.
Define your shell scripts appropriately and save them there.
They get executed in the order presented in the directory.
You have here a melange of things (in post #5)
that would surprise me if it did anything useful as it stands.
Perhaps 'try it and find out' is a bit premature.
In regards to I/O re-direction, of any sort, I can't help you.
I think you will get more help from some quarter if you
define in words, more than a short sentence just what you hope to achieve.
post #7 got past me with the darn ten minute edit rule
wrong
/etc/rc.local is an executable script itself.
your can reference other scripts in it.
Best to keep things small and separate.
Remainder of my post #7 about right, I think.
I copied script.sh inside /etc/
#!/bin/sh
clear
read -p "Insert your Windows installation disk and press a key to continue" disco
sudo mount -t auto /dev/cdrom /mnt/cdrom
dosemu
I call it inside the /etc/rc.local file :
rc.local
....
/etc/script.sh
I made it executable,with chmod +x script.sh
and at the end I re-booted Knoppix with runlevel 2,but when it has finished to be loaded in memory,the script.sh is not started.
Since you made it executable it is better to remove the .sh extension and place your script in /usr/sbin, then make a line in /etc/rc.local
Make sure again it is chmod 755
rc.local is the last script executed at every runlevel 2,3,4 and 5
Dell PowerEdge R730 2x E5-2699V3 2.3Ghz 36 Core 128GB RAM H730 X520-I350 2x750W
$329.99
Dell PowerEdge R630 Server 2x E5-2680 V4 = 28 Cores S130 32GB RAM NEW 480GB SSD
$197.99
Dell Poweredge R630 2x Xeon E5-2680 v4 2.4ghz 28-Cores / 128gb / H330 / 2x 1TB
$334.99
Dell Poweredge R730xd LFF 14-Bay 2U Server | Choose Your CPU & RAM Config
$489.99
Dell PowerEdge R630 Server 2x E5-2640v3 2.60Ghz 16-Core 64GB H330
$182.65
Dell Poweredge R630 Server 2x E5-2620 V4 =16 Cores | S130 | 32GB RAM | 2x trays
$159.99
DELL POWEREDGE R630 8 x 2.5'' 2X E5-2680V4 32GB RAM IDRAC ENT & NDC 2X 495W PSU
$184.95
1U Supermicro Server 10 Bay 2x Intel Xeon 3.3Ghz 8C 128GB RAM 240GB SSD 2x 10GBE
$259.00
1U Server ( 4x VM's ) Hosting VPS Short Depth 20" 1U Xeon 3.5Ghz 16GB X10SLM-F
$149.00
Dell PowerEdge T620 8-Bay LFF Xeon E5-2660 0 2.20GHz 48GB NO HDD S110 Server
$174.99