Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
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.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
We have a windows exchange server setup where multiple windows pc's are connected to it's domain. The exchange server has the domain of "company.local" and any windows machine connected to this domain has something like "computername.company.local".
We have a few other platforms on our network (Mac/Linux) and their DNS server is set to this windows server so these local domain names are reachable. So I can ping "computername.company.local" from my unix box, mac, or windows box.
The linux box we have on our network serves as a local web development server. Currently I have to use it's local ip address to access it, which changes from time to time because it's on a DCHP server. I tried changing the hostname to "dev.company.local", but that doesn't seem to make it reachable by the other machines on the network.
I heard that I need something called samba, but I am unfamiliar to how this works. I don't really need/want windows file sharing, I just need to be able to access it from any machine with "dev.company.local" rather than the IP address. Thus, it needs to join the windows domain, which I am unsure how to do this.
If you have a Windows domain set up, do you also have your DNS server setup locally? If so, then just adding a A record for the linux machine, in combination with a DHCP reservation will do the trick without installing anything. That is if you're only looking to access the machine using computername instead of IP. With DHCP reservation I mean that you make a permanent reservation in your DHCP server for the linux server. After that enter a DNS entry for the linux server stating its name and IP. If your not sure how to make a DHCP reservation then of course you can opt to change your linux NIC setting from DHCP to STATIC.
In doing this your linux machine will be 'reachable' using the servername in the domain. No need for Samba, smbclient or anything.
Without statically assigning an IP with an A record, how would I go about getting it on the windows domain? Is samba the only option? If so, how would I go about setting that up? I need for it to automatically connect to it on boot and have the host name reflect what the domain on the server is.
If you don't want to set up DHCP nor DNS and want to join the Linux box to a Windows domain, then you'll need at the least Samba and Winbind. There are various how-to guides on the internet, some listed below.
You're welcome. There is no difference between Samba and Winbind since they are not really separate programs to install. Winbind comes as a part of the Samba suite.
winbind is a component of the Samba suite of programs that solves the unified logon problem. Winbind uses a UNIX implementation of Microsoft RPC calls, Pluggable Authentication Modules (PAMs), and the name service switch (NSS) to allow Windows NT domain users to appear and operate as UNIX users on a UNIX machine. This chapter describes the Winbind system, the functionality it provides, how it is configured, and how it works internally.
As stated in my previous post, if you want to join the Linux box to the AD domain, then you'll need Samba. If it's only to access the webserver on the linux box using a domain name instead of IP, using DHCP or not, then you don't need Samba and just can configure DNS and DHCP on your Windows domain controller, that is if you have access to it. Your choice depends on what you need. Samba can be simple but can do very complex things too, so really, depends on what you want it to do.
I've installed samba using "yum install samba". I edited the default smb.conf and set the following:
Code:
workgroup = company.local
netbios name = dev
security = domain
passdb backend = tdbsam
password server = company.local
I then tried "net join company.local" and I get "Unable to find a suitable server" twice.
I'm largely confused in how to correct this. I am not all that familiar with how a windows domain works. I generally work with linux web servers and stay as far away from windows as possible, so generally my experience in samba is nill.
I also don't really have access to the windows exchange server. All I really have is a user and password to join the network from a window box. I could request access, and/or get a user for the linux box (if required), but my goal is just to get it to connect to the windows domain controller so the domain controllers DNS will automatically feed 'dev.company.local' into the other machines on the network. (If what I do can be limited just to the linux box, I would prefer that, rather than tinkering with the windows server).
I am not all that familiar with how a windows domain works. I generally work with linux web servers and stay as far away from windows as possible, so generally my experience in samba is nill.
Good for you if you can stay away from Windows!! But in order to understand the beast you once in a while have to enter the stable.
I'm currently in the process of trying to migrate as many Windows servers (total of 62) as possible to Linux and believe me, I'll be a happy man when the task is finished.
Ok so assuming that the server name is "server1" it's pingable hostname is "server1.company.local". Do I set "password server" to "server1.company.local"? Also in the configuration comments it says something about needing realm for ads. Do I supply this, and if so, what do I put in it?
If you set security to ADS and your domain uses Kerberos authentication protocol then the realm should list your kerberos realm. Since you don't have access to the Active Directory, that's something you'll have to ask your sysadmin for.
Well I pretty much figure out what my real problem is. I needed some kind of name to connect to for the web server, and the host name was not pingable... The DNS is set to the exchange server on our machines.
I'm assuming that the DNS on the exchange server is set to the main router. BUT my computer and the web server is behind a second router, so the DNS on the primary router doesn't see the web servers host name. As soon as I added the router I'm behind as a DNS server, I'm able to ping the hostname of the web server. So we need to fix our network issues, and then I can just ping "dev.local" which is shorter anyway .
That is indeed a shorter way! And judging from your last post, you don't need to install anything on your webserver.
Hope it works out and you can get the network issues solved, shouldn't take much time, at least less then installing and configuring Samba to join your Windows domain.
I fixed the issue by turning the wireless router into an access point. I've found that our primary router also has it's DCHP turned off, and DCHP is being served by the exchange server itself.
Now dev.local, my web servers host name, is pingable, and all our computers are on the correct 10.1.10.* range (whereas before those behind the wireless router, including my web server, were on 192.168.10.*).
The problem I'm having now is that connection to a page through http://dev.local/ is extremely slow. It takes almost a minute just to load all the images on the page. This did not happen when I added the wireless router to the DNS list on my machine. If I access it directly through the ip address, it works normally.
Is there still something screwy with the setup, or is the DCHP server on the exchange server really slow? I'm not even really sure WHY it's serving the DCHP when the primary router could have easily done this.
I'd rather leave things the way they are now, but I can't have pages being served this slow through dev.local.
Perhaps I should start a thread in the networking forum?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.