Arch Linux: Configuring SAMBA
HTML-код
- Опубликовано: 11 сен 2024
- In this video we are going to see how to configure SAMBA by first installing and configuring it on a server, and then we are going to connect to it through a client and mount it permanently.
Samba is the standard Windows interoperability suite of programs for Linux and Unix. Since 1992, Samba has provided secure, stable and fast file and print services for all clients using the SMB/CIFS protocol, such as all versions of DOS and Windows, OS/2, Linux and many others.
Arch Linux Wiki SAMBA: wiki.archlinux...
** Become a Patreon to support the channel: bit.ly/3dGGZxQ **
** Follow Us on Twitter: bit.ly/3gKkPeR **
*** Follow Us on Instagram: bit.ly/3c4QDtK
** Donate to the channel by visiting our Website **
My Hardware:
AMD Ryzen 9
32 GB RAM
Sapphire RX 5700 XT
My software:
Distro: Arch Linux
Video editing software: Kdenlive
Music: www.bensound.com
Check out our Website and connect on Social Media!
Website: ermannoferrari...
Facebook: / ermannoferrariit
Instagram: / efsoftwareandit
#howto #archlinux #samba
Halfway through the video and I immediately subscribed, this is one of the clearest tutorials I've watched on... anything really. I don't even care if it works at this point, I'm just glad I found your channel. Keep doing what you're doing :)
Been trying to create a samba server on my ArchLinux i3wm build, this is one of the more extensive install guides I've seen so far
I finally landed on this video after bricking my laptop twice trying to setup permissions watching lots of confusing videos.
Hermano, thank you very much for making this tutorial. Keep up the good work
Glad it helped!
Thank you Ermanno! Another valuable video on setting up shared file services.
Glad you enjoyed it!
Keep up with the good work, in Manjaro there is a package called manjaro-settings-samba with the smb.conf file, it also enables the systemd samba services (smb and nmb). If you install nautilus-share (in a gnome based desktop) you get the option to share folders directly from the file explorer.
Thanks for sharing!
Ciao Ermanno!
Thank you so much for your great tutorials. It's a joy to watch you working - straightforward, efficient and informative. I've subscribed *immediately*. You've covered many of the tasks I tried before, some successful, some not so much. I'll definitely switch back to Arch (from Manjaro) on my main machines, now that I have new confidence through your videos.
However, the new build I am planning is still a handful, and I would have to piece together several of your guides to make it happen and still had some more topics to investigate. Maybe more people are interested and could motivate you to look into it?
The task: Set up an Arch home server that offers DNS, DHCP and basic firewall tasks (to replace my pfsense host), auto-connects to my VPN provider, filters ads, acts as a file server with NFS4 and Samba and runs Nextcloud. And maybe music player deamon. All this on a UEFI install with encrypted btrfs and snapper. To start this in headless mode a keyfile on a USB stick will be necessary. While we're at it, a Pacman cache and headless Transmission would also be nice.
Bonus challenge: I want to run this server as WLAN provider for laptop/mobile phone/tablet and guests as well. It should replace my internet router completely and be the base machine for all networking tasks.
Interesting?
That's a great menu :)
This is actually a very good quick guide.
There are better alternatives if you're only using linux systems, but samba is still better if you need to share with many windows pcs, especially if not all Windows pcs are up to date.
Thank you very much! I have been looking for 2 days for a good guide. This explains everything I had questions on. Thank you again for your time.
Great video, got me started with the samba drive, mapped to a windows and arch client from arch server.
Hey Mike! Glad it was helpful!
I was struggling for long time to get this done thanks a lot.
Awesome video 🙏
This was absolutely awesome. All the problems I was having were answered in this video. Thank you very much!
Great video as always Ermanno! I don't think you need "read only = no" if you have already defined "writeable = yes".
Yeah, I noticed that after I edited the video :)
I believe the uid and gid values provided in the mount command should correspond to the LOCAL (e.g. client) user/user group and not the SERVER as described in the video.
The issue is that we are mounting the CIFS share (~/server) as root (due to the usage of sudo), so you cannot write to the mounted directory as normal user (even it’s located in the user’s directory). The uid and gid would allow that particular user and group to write to the share (as you have demonstrated).
This video is perfect tutorial. Thank you so much Ermanno.
You're very welcome!
Thank you for making this video. Very helpful.
Glad it was helpful!
Best configuration video so far, thanks man
Very helpful. . . Thank You! I hope you current job/adventures age going well.
excellent my samba works now thanks a lot
Ran into a video where someone talked about going from Ubuntu to Arch. Then, I started searching for how to get Samba working on Arch and found this. If these Linux derivatives work for everyone else, fine. As much as I'd rather get away from Windows, it's file sharing service is still so much easier and straight forwards for me to use. Heck, Ubuntu was the one operating system I was using just to have something to do regular office work with. Then, at some point, they dropped support for Samba. Even the company my dad worked for used to have a command-line operating system server that they were constantly fighting to keep working: Isilon. I don't know what they replaced it with.
Thanks for sharing, I honestly didn't know that about Ubuntu. I am curious to check it out.
@@eflinux
The main thing they said was that Ubuntu was no longer compatible with Samba. That's why they dropped it. Either that or I confused it with the fact that users were having problems with Samba continuing to drop their shares. But, that was years ago and, for all I know, things may have changed since then. I can't remember if the last version I tried was 12, 14, or 16.
@@renegade637 Getting Ubuntu to work with Samba is a big pain because of a few things. The first is that the version of Samba in the repository is very far behind the latest Samba versions. The next issue is setting up your flavor of Linux to be a Samba Domain Controller. If you read the Samba pages you'll see that even they say that the install scripts do not properly set permissions for things like Bind9 to work. Also, there are different version of Bind9 that have to be used depending on which version of Samba you are running. None of this stuff is fully baked in my opinion.
EF, I only watched a little of your video so I don't know if you attempted to make Arch a domain controller but if you didn't, I would love it if you could put together a "Running Arch Linux as a Samba Domain Controller" video. That would be amazing and would be the only video of its kind on RUclips as far as I can tell. This will be a challenge, though. There's a lot of "gotchas" on the Samba pages regarding Bind9, Samba versions, and permissions. But this would be a "Windows Killer" as far as I'm concerned!
Idk if this can help me to setup samba on Manjaro, but I'll try it anyways. Hope you can talk about this topic on a next video.
you made my day, thanks
thanks for the video, works fine
Thank you, after a lot of suffering, finally my arch is networked with, mint, ubuntu and windows ...it helped a lot a layman in arch base like me, I suggest a tutorial on how to share the server's hd on the local network, good luck on the channel .
It worked wonderfully, very well explained. Personally, I am looking for a tutorial that shows how to have this configuration with a graphical interface. I come from Manjaro and there with installing the package "manjaro-settings-samba" (AUR) I could do all this from a Share tab in the properties of the folder in question, but in Arch I can't find that package or something offer me such server-side convenience for directory sharing. Hopefully you can help me and thanks again, you have earned a subscriber
I will have to look into it. What I usually do is install the avahi daemon and have to adjust some settings for the autodiscover function to work.
@@eflinux 😇
@@eflinux
a) I noticed that Manjaro get that GUI function by installing the "manjaro-settings-samba" package, but in Arch I can't find it (yay helper). Is it a special mirror in Manjaro or a package that only appears if we use Manjaro?.
b) In other hand I also try is add my user to group "sambashare" and I got a "usermod: group 'sambashare' does not exist" message, but samba is installed and the service "samba.service" loaded.
c) I also noticed is that in Manjaro (updated mirrors), install the samba-4.14.0-1 version, while Arch the 4.14.2-1, do you suggest I do a downgrade?
Sorry for so many questions but I have a couple of months on GNU / Linux only
I don't think the issue is the version, and also I am not sure sambashare is the group created by installing samba. Depending on the DE you use, share should be appearing in the file manager if the avahi daemon is up and running.
Thanks a lot Ermanno. Great tutorial.
You just had to put this out within the week I got my old HP back up and running to betatest Arco ISO's, and the thought of networking it to the main machine sprang to mind. So far I've held off, though I have a better idea what I'd like to not get myself into yet, but who knows? :)
Btw, are you still planning a further looksee of Arco? Our Dwm is out now.
Are you working with Arco?
@@eflinux Some betatesting, some website revision.
very good. thank you ermanno
Perfect, thanks.
Thanks Ermanno. Is there an easy way to make these samba shares show up in the windows network folder, now that SMBv1 is out of the window? I saw there is an AUR packages for wsdd but have not tried that yet.
5:10 samba config
7:48 cmd
15:35 fstab
8:40 you connect to the shared folder using smh://192.168.122.14/sambashare but you defined it previously in the config as "samba" is it an imprecision due to the fact that you may have changed your mind lately or while editing the video or I am missing something?
I defined the path to /samba, but as you see at 03:33 then name of the share is [sambashare].
@@eflinux right I completely miss it! Thank you
If you get an error after reboot that says mount.cifs:permission denied this can be fixed by adding your domain to the etcfstab file. domain=yourdomain. Perhaps ermmano will cover this in a follow up video?
Great!
If I try enabling the smb & nmb services, systemctl status gives me: "reopen_one_log: Unable to open new log file '/usr/local/samba/var/log.smbd': No such file or directory". Does anybody know how to resolve this? The share doesn't work for me, most likely due to that error...
You rock!
Hello, I have this issue "mount error(115): Operation now in progress" How do I solve this?
Perhaps I should have used different values, but I set up a Samba share on my main Arch Linux box, then created a dual-boot Windows 10 and Arch Linux VM using Virtual Machine Manager (I used GRUB this time). I was able, in Windows 10, to connect to the samba share, although I keep having to enter my credentials, which is not an issue. On the Linux client, however, I keep getting a logon failure message (I checked in dmesg). I'm using the same credentials for the samba share as for my standard user account on my primary linux box. Coudl that be an issue?
Have you given the user a specific samba password?
thanks for explain but security wise can't do what you have done able login automatically with username and password when mount...have it prompt for username and password
dont work for client with thunar why?
when I try to mount with cifs it gives me a kernel panic, I follow all the steps but it doesn't work, I am trying to share a folder between two arch linux systems ):
Followed the steps yet I am getting Access Denied on client when trying to do any commands, even the ls
Thank you, this is the really helpful video. I have problem about permissions. In client side, I made what you show on video but I still my mounted file owner permissions are missing. How do I solve this? Could you help me?
You'll have to switch to the root user in the client and try again.
cant connect on client 'connection refused'
There are so many better options these days. SSHFS is better and more secure. If you are away from your LAN, syncthing is a great way to get access to a box. Samba on LAN is fine but once you move outside your LAN it's a security risk.
Yeah, however SAMBA is still quite popular.
SSHFS, thanks! I followed this video and my samba had a bunch of authentication issues. Installed SSHFS, soooo much better.
SSHFS is no longer maintained or developed :(
You didn't tell us what's samba, not all people know it.
It is in the description.