Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
do things automatically
#1

Hi,

 

I've installed Debian 4 on my PC.

Over the last couple of days I have managed (somehow) to mount my NTFS drives, get the sound working, and get the internet to work over the wireless.

 

A couple of questions though.

 

At the moment, every time I reboot / log in I need to mount the NTFS hard drives and run the modprobe ndiswrapper command in order to try and get things to work.

 

Any chance that these things can get done automatically during boot up or log in?

 

Thanks,

 

Ori

Reply
#2

i add my boot time commands to /etc/rc.d/rc.local

 

cheers

anyweb

Reply
#3

Yeah so debian doesn't use rc.local.. if you want to do something like rc.local then you need to do the following:

 

Make a file /etc/init.d/ntfsmount



Code:
#!/bin/sh
#  ntfsmount -- startup/shutdown script for my NTFS mounts!

case $1 in
start)
mount -a -t ntfs
  ;;
stop)
umount -a -t ntfs
  ;;
esac




 

That will create a script that will mount and umount all the ntfs partitions in your /etc/fstab file. A similar file for the modprobe can made, indeed you can put both commands in a single file.

 

After that you then need to do this:



Code:
$ chmod 755 /etc/init.d/ntfsmount
$ update-rc.d ntfsmount defaults




 

You might find that the "defaults" option isn't appropriate but you can read about how to use update-rc.d better.

 

Enjoy :)

Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)