sambagk is a simple Bash-based tool for managing the Samba server via a terminal menu interface on Ubuntu systems. It provides options to start, stop, enable, disable, check the status of the Samba server, and edit the Samba configuration file.
- Start the Samba server
- Stop the Samba server
- Enable the Samba server to start on boot
- Disable the Samba server from starting on boot
- Check the status of the Samba server
- Restart the Samba server
- Test the Samba configuration (
testparm) - Edit the Samba configuration (
smb.conf) usingnano - Simple installation and uninstallation scripts
- Checks if
smbd(Samba) is installed, prompting users if it’s missing
-
Download the scripts:
git clone <repository-url> cd <repository-folder>
-
Make the scripts executable:
chmod +x sambagk install_sambagk.sh uninstall_sambagk.sh
-
Run the installation script:
./install_sambagk.sh
The installation script will:
- Copy
sambagkto/usr/local/bin/for global access. - Ensure
sambaandnanoare installed.
After installation, simply run in Terminal:
sambagk- Start Samba server
- Stop Samba server
- Enable Samba server (auto-start on boot)
- Disable Samba server
- Show Samba server status
- Edit Samba configuration (
/etc/samba/smb.conf) - Restart Samba server
- Test Samba configuration (using testparm)
- Exit
To remove sambagk from your system:
./uninstall_sambagk.shThe uninstallation script will:
- Remove
sambagkfrom/usr/local/bin/ - Optionally ask to remove Samba from the system
- The script uses
systemctlto manage the Samba service (smbd). - Editing the Samba configuration (
smb.conf) requiressudopermissions. - Ensure Samba shares are properly configured after editing the configuration file.
If you encounter issues or have suggestions, feel free to open an issue or submit a pull request.
MIT License. See LICENSE file for details.
Contributions are welcome! Please:
- Fork the repository
- Create a feature branch
- Commit changes
- Submit a pull request
Enjoy managing your Samba server with ease! 🎉