Tiny Core Base > TCB Talk
starting mongodb in bootlocal.sh
salmankhalid:
Hi all
I am trying to start mongodb on system startup. I have added the following line to the bootlocal.sh
/usr/local/bin/mongodb/bin/mongod --dbpath /mnt/sda1/own/db --journal --fork --syslog
this doesn't start mongodb but if i change the --dbpath option to /data/db it works and starts up. As
tiny core is booting from sda1, so i imagine that sda1 will be mounted .. i have also tried
/usr/local/bin/mongodb/bin/mongod --dbpath /mnt/sda1/own/db --journal --fork --syslog &
/usr/local/bin/mongodb/bin/mongod --dbpath /mnt/sda1/own/db --journal
/usr/local/bin/mongodb/bin/mongod --dbpath /mnt/sda1/own/db --journal &
but still mongodb won't start, I want save the db on disk so that i don;t lose any data on system crash and restarts
Thanks in advance
gerald_clark:
Core does not know where it booted from.
Unless the tce, home, or opt are on sda1, it will not be mounted.
Mount it in bootlocal.sh before you start the database.
malikawan:
Add "sudo mount /mnt/sda1" and then enter ur code in bootlocal.sh may be it work for u.
Malik Awan
gerald_clark:
Do not use sudo in bootlocal.sh. It runs as root.
just add
mount /mnt/sda1
salmankhalid:
Thanks guys for the quick responses ... but it I'm still unable to start the db with the --dbpath /mnt/sda1 option ... :( ... i have put the mount command in bootlocal.sh before the db startup .. The machine is currently at a remote location so i can't see boot errors on screen also i can;t find mongodb in dmesg but i am not sure if that is the right place look for errors that happen in bootlocal.sh ...
Navigation
[0] Message Index
[#] Next page
Go to full version