• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Simple smb passwd question

smp

Diamond Member
I forgot how to sync up system passwords and smb passwords.
Anyways .. right now when I do a
smbpasswd $user
I get the following:

New SMB password:
Retype new SMB password:
unable to open passdb database.
Failed to find entry for user stevan.
Failed to modify password entry for $user


I know I have to create a smbpasswd file .. right?
How though?

edit:
Okay,
smbpasswd -a
Adds the user to the file .. this seems to be working. I can't see the machine in network places though :|
This happened to me before and I never got a fix for it.
It seems though, that my windows box has cached the old /home .. so it's not showing me what's in there now, just what used to be in there before i reinstalled that machine .. weirdness
I hit refresh and it's the same thing .. dumb


Anyone know how to add users in cli in redhat?
adduser
useradd
don't work
don't know what to do .. or how to find out.
Can do it in gnome though :\
Don't really like using the X though for admin stuff
 
SMB browsing is crap, eventually it'll sync up and network places'll work. If you can type \\servername in explorer consider that success unless you have a box doing WINS.
 
Originally posted by: Nothinman
SMB browsing is crap, eventually it'll sync up and network places'll work. If you can type \\servername in explorer consider that success unless you have a box doing WINS.

Yup .. that's the only way I can connect SUCCESS! 🙂
Still though, I need to add some users and I don't want to have to resort to doing it in gnome.
You got any ideas? Adding users from cli ??? (redhat 7.3)
 
Did you su to root via 'su' or 'su -'.

The - is important because it makes the shell a login shell which sets all the important environment variables like the PATH.
 
Originally posted by: Nothinman
Did you su to root via 'su' or 'su -'. The - is important because it makes the shell a login shell which sets all the important environment variables like the PATH.

REALLY?!!
I've never heard of that .. I'll give it a try
 
it worked!
Now .. how do I remove a user 🙂

edit:
userdel

got it!

Hmm .. I want to make it "no login" .. so that this user has no access to CLI .. just samba /home
I can do this in gnome . but.....

useradd -s (shell)
but .. can I useradd -s nologin ? .. or /dev/nul (is it dev/nul?)
okay .. seems to work 🙂

[root@red root]# su music
su: cannot run /beat/IT!: No such file or directory




 
It might be better to set the user's shell to /bin/true and add /bin/true to /etc/shells, some programs won't authenticate if the user's shell is invalid.
 
Originally posted by: Nothinman
It might be better to set the user's shell to /bin/true and add /bin/true to /etc/shells, some programs won't authenticate if the user's shell is invalid.

What does that do? What is 'true'???
I don't want the user to have shell access.
The method that i described above (which is what it's set to now) just gives them an error when they try to log in .. even though it's kind of crude, it works, they can't log into a shell, just smb. Kind of crude though still, there has to be a better way.
/bin/true ?? is the better way?
 
TRUE(1) User Commands TRUE(1)

NAME
true - do nothing, successfully

SYNOPSIS
true [ignored command line arguments]
true OPTION

DESCRIPTION
Exit with a status code indicating success.

/bin/true just returns 0 then exits, nothing else. So if they try to login they get kicked right back out. And it's real command so you can put it in /etc/shells and have things like imap servers not deny logins because of bad shells.
 
Back
Top