Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I did something wrong somewhere, because this was working before I started tinkering with the smbconf file using gedit (lesson learned, but I normally don't trust the GUI).
Here is the output when I try to run the Samba Server Config tool from a command line...
[root@localhost /]# redhat-config-samba
Traceback (most recent call last):
File "/usr/share/redhat-config-samba/redhat-config-samba.py", line 20, in ?
mainWindow.MainWindow(debug_flag)
File "/usr/share/redhat-config-samba/mainWindow.py", line 58, in __init__
self.samba_data = sambaParser.SambaParser(self)
File "/usr/share/redhat-config-samba/sambaParser.py", line 24, in __init__
self.parseFile()
File "/usr/share/redhat-config-samba/sambaParser.py", line 55, in parseFile
token = self.createToken(line)
File "/usr/share/redhat-config-samba/sambaParser.py", line 127, in createToken token = sambaToken.SambaToken(sambaToken.SambaToken.SAMBA_TOKEN_KEYVAL, (name, value), self.parent)
File "/usr/share/redhat-config-samba/sambaToken.py", line 20, in __init__
raise AttributeError, value
AttributeError: ('only guest', 'yes')
I have the exact same issue - I got what I wanted out of hand-editing the file so I figured why bother fixing it. I guess it would be nice if it worked the way it was supposed to though.
Call me lazy - but it's been a long day.
The only difference with mine is the last line:
AttributeError: ('share modes', 'no')
Sure. The reason I need the gui is because I think I messed up my smbuser or smbpasswd files...I am confused over accounts at this point, and when I could not get the GUI back I was getting worried.
I have only included the lines that are not commented out:
[global]
workgroup = MSHOME
hosts allow = 10.1.1 127.
server string = My Samba Server
encrypt passwords = yes
pam password change = yes
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
dns proxy = no
[homes]
comment = Home Directories
browseable = yes
writable = yes
valid users = %S
create mode = 0664
directory mode = 0775
[printers]
comment = All Printers
path = /var/spool/samba
browseable = no
guest ok = no
writable = no
printable = yes
[public]
path = /var/myweb
public = yes
only guest = yes
writable = yes
printable = no
Don't see anything particularly wrong with that. I don't know why the tool won't parse it for you. Run testparm from the command line and see if it gives you any errors.
This may seem a bit crazy, but until I could find the actual error, I commented out lines 19 & 20 of /usr/share/redhat-config-samba/sambaToken.py and it looks like it's working fine.
I'll post again when I've found the actual error - but I'm pretty sure it's got nothing to do with your samba configuration.
Note that I'm not recomending this as a fix - those line appear to specifically exists so that if the app thinks there's something wrong with it, it can exit gracefully. However, it does look usable in this state (for the moment anyway)
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.