nano /etc/xinetd.d/swat
Here’s my swat file:
service swat
{
port = 901
socket_type = stream
wait = no
only_from = 127.0.0.1
# only_from = 192.168.0.4
user = root
server = /usr/sbin/swat
log_on_failure += USERID
# disable = yes
}
By commenting out disable = yes, you allow xinetd to start SWAT.
Notice that I allow access to SWAT only from the machine that SWAT is running on (127.0.0.1 is the loopback address). If I wanted to allow another machine on my LAN to access and edit SWAT, then I would remove the comment in front of only_from = 192.168.0.4. You would need to change the IP address of the machine, of course.
Now restart xinetd:
/etc/init.d/xinetd restart
To actually use SWAT, you need to point your Web browser to the IP address of the machine you referenced in your swat file. After the IP address, append the port number of 901. So in my case, I would use the following URL:
At the prompt, enter the following:
User ID: root
Password: root’s password
At this point, you’re ready to start editing your Samba configuration!