RSS

Samba vs. Networkmanager

14 Jan

A 3.6-os Samba valahogy nem fer ossze a Networkmanagerrel, igy kenyetelen voltam egy kis dispacher szkriptet gyartani az /etc/NetworkManager/dispatcher.d/ mappaba. A szkriptnek lehet teszoleges neve, a tulajdonos legyen root es legyen futtathato.

Ime a tartalma:

case “$STATUS” in
‘up’) # $INTERFACE is up
exec /etc/rc.d/samba start
;;
‘down’) # $INTERFACE is down
# Check for active interface and down if no one active
if [ ! `nm-tool|grep State|cut -f2 -d’ ‘` = “connected” ]; then
exec /etc/rc.d/samba stop
fi
;;
esac

Mas nem marad hatra mint az rc.conf-bol kivenni a sambat a demonok kozul. Mindez Archlinuxra ervenyes.

Advertisements
 
Leave a comment

Posted by on January 14, 2012 in Linux

 

Tags: ,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s