LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   Fail to add the new pc for the domain controller (https://www.linuxquestions.org/questions/linux-server-73/fail-to-add-the-new-pc-for-the-domain-controller-550827/)

uchuanng 05-02-2007 09:11 PM

Fail to add the new pc for the domain controller
 
I was face the problem, when i telnet to Linux server i try to add the new pc for the domain controller, i use the below command.

useradd -g machines -d /dev/null -c "Trusted Machines" -s /bin/false nhc081$

but the error message display

unknown group machines.

jschiwal 05-02-2007 09:52 PM

Did you get this example from the Samba3-Howto guide?
You may have skipped the part about creating a Unix group for the Machine Trusted Account group. There example used the group "machines" with a GID of 100.

Also check on the server, because maybe a different group name is used.
Another thing to check, is for a "add machine script =" entry in smb.conf. This entry will be essentially the same as the command you are using to manually add the machine. If you have this script it is better to try to join the domain from the windows machine (using the Domain Administrators password) and let Samba automatically create the Unix/Linux account for the machine. This way you don't have to make sure that you log on right away.

I would recommend reading chapter 6 of the Samba 3 Howto and Reference guide. You may have a samba-doc package that supplies it, such as in /usr/share/doc/packages/samba/Samba3-Howto.pdf. On some distro's the samba package supplies a postscript version. Otherwise, go to the Samba.org website and download a copy.

uchuanng 05-02-2007 10:45 PM

Quote:

Originally Posted by jschiwal
Did you get this example from the Samba3-Howto guide?
You may have skipped the part about creating a Unix group for the Machine Trusted Account group. There example used the group "machines" with a GID of 100.

Also check on the server, because maybe a different group name is used.
Another thing to check, is for a "add machine script =" entry in smb.conf. This entry will be essentially the same as the command you are using to manually add the machine. If you have this script it is better to try to join the domain from the windows machine (using the Domain Administrators password) and let Samba automatically create the Unix/Linux account for the machine. This way you don't have to make sure that you log on right away.

I would recommend reading chapter 6 of the Samba 3 Howto and Reference guide. You may have a samba-doc package that supplies it, such as in /usr/share/doc/packages/samba/Samba3-Howto.pdf. On some distro's the samba package supplies a postscript version. Otherwise, go to the Samba.org website and download a copy.

Thanks for help.
i got 1 more question how to entry in smb.conf in the "add machines script=" can you write to the full script to me?

jschiwal 05-02-2007 11:28 PM

Here is an example from a Red Hat 3 configuration that Samba 3: Howto and Reference uses:
Code:

[global]
        ...
        add machine script = /usr/sbin/useradd -d /var/lib/nobody -g 100 -s /bin/false -M %u
        ...

In their example, the group "machines" is uses and it has a GID of 100.
This example is very close to yours. The "-M %u" is a dynamic variable which depends on the machine that is trying to be added.

Do you have a "machines" group added?
I would again highly recommend reading that chapter in the Samba 3 book. There is a new edition of "Using Samba" out that is very good as well. This book is in the book stores.

melvinong 05-03-2007 12:37 AM

hi!guru...nice to meet u...

How to check whether the group "machines" is exist in the domain?

If no exist,how to create the group "machines"?

Is that any effect to those existing PC which previously created under group "machines" after create the group "machines"?

jschiwal 05-04-2007 01:43 AM

Quote:

Originally Posted by melvinong
How to check whether the group "machines" is exist in the domain?

The machines group is a linux group. Check if it exists in /etc/group. Also scan through the samba3-Howto manual for examples of the net command. It is used for various things like listing Admin groups.
Quote:

If no exist,how to create the group "machines"?
You can use the "groupadd" command, or your distro's users & groups gui config program. It may be created by samba, for example, you might be using samba swat to configure smb.conf. You could run the wizard to create a stand-alone pdc. It might create the group for you. Look at the "add machine" entry of smb.conf for which group it is.
Quote:

Is that any effect to those existing PC which previously created under group "machines" after create the group "machines"?
If this group doesn't exist, then there are no members. If there are members, it must already exist.

Note that there are other backends that you might use as well. For example, for "security = ad", the "add machine script =" value will use an ldap script instead.

melvinong 05-04-2007 02:32 AM

manually add group "machines"
 
Can i manually add in the group "machines" in /etc/group?
Any side effect, because "groupadd" command not working....

jschiwal 05-04-2007 05:27 AM

You need to be root to run the command. If you use sudo, precede the command with the directory, as in sudo /sbin/groupadd or sudo /usr/groupadd, whichever the case may be. You can also use the try "locate groupadd" or use your distro's gui "groups & Users" config program. Your distro may call the script something else as well. You will need to read your distro's documentation if "groupadd" isn't available.

Be sure you follow the instructions in the Samba3-Howto or the Samba3-byExample book. There are several steps to configuring a Samba Standalone PDC. Using swat may make the process easier as well.

(I thought you had Mandriva in your profile earlier, otherwise this next statement won't make sense)
Also, make sure that you have the wizdrake package installed. It may have a wizard for configuring a samba server.

melvinong 05-08-2007 07:16 PM

Network Connection Failed
 
I have install linux redhat 9.0 to the new PC, but after finish install, i tyr to ping to other PC, no reply at all, WHY?
anyone can help me solve this problem?

melvinong 05-08-2007 07:24 PM

I have install linux redhat 9.0 to the new PC, but after finish install, i tyr to ping to other PC, no reply at all, WHY?
anyone can help me solve this problem?


All times are GMT -5. The time now is 04:50 PM.