[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[debian-knoppix] loading data into ramdisk during startup



Hi,
while remastering a knoppix-build (starting from standard 3.2, latest release), I stumbled across the following I would like to start up apache and mysql. I did this by update-rd.d'ing the respective initscripts and everything seemed to go smoothly. However, after building the .iso-File I realized that I had forgotten to remove /var/lib/mysql/Knoppix.err and mysql startup failed. Now that's my own fault of course, but it led me to this question. When using the faulty cd (with the above mentioned error) I can't even start mysql manually (>/dev/null 2>&1 removed from the script):

root@ttyp0[knoppix]# /etc/init.d/mysql start
Starting MySQL database server: mysqldtouch: kann »/var/lib/mysql/Knoppix.err« nicht berühren: Das Dateisystem ist nur lesbar
Starting mysqld daemon with databases from /var/lib/mysql
/usr/bin/safe_mysqld: line 231: /var/lib/mysql/Knoppix.err: Das Dateisystem ist nur lesbar /usr/bin/safe_mysqld: line 237: /var/lib/mysql/Knoppix.err: Das Dateisystem ist nur lesbar
tee: /var/lib/mysql/Knoppix.err: Das Dateisystem ist nur lesbar
030911 06:48:41  mysqld ended
tee: /var/lib/mysql/Knoppix.err: Das Dateisystem ist nur lesbar

...failed.

It says that /var is on a read-only filesystem. If you look at
root@ttyp0[/]# file /var
var: symbolic link to `/ramdisk/var'

and realize that /ramdisk/var is in itself merely a symlink to /KNOPPIX/var then it becomes obvious. But if I change /var/lib/mysql/Knoppix.err by hand (using vi and saving the changes) it gets transferred to the ramdisk and is from then on writable. A real problem occurs when you try to fopen() a file using php. "Failed to create stream" is your foe then. Somehow it seems illogical to me that the files are transferred to ramdisk when one edits them by hand and not if a process tries to change them.

So my question is: Is it possible (and if so how) to preload certain files into the ramdisk during startup process?
Any help on this matter is greatly appreciated.

TIA,
Christoph

_______________________________________________
debian-knoppix mailing list
debian-knoppix@linuxtag.org
http://mailman.linuxtag.org/mailman/listinfo/debian-knoppix


Reply to: