Run the sudo visudo command, and add the following line at the end of the sudoers file (replace user with your user name on the local machine): user ALL = NOPASSWD: /usr/bin/mount To do this, use the which mount command to find out the exact path to the mount tool (e.g., /usr/bin/mount). To prevent this from happening, add mount to the sudoers list. Since the mount command in the script requires root privileges, the script prompts you to enter the root password every time you run it. Save the script under the digikam-launch.sh name and make it executable using the chmod +x digikam-launch.sh command. Sudo mount -t cifs //ipaddess/path/to/dir /path/to/local/dir -o user="user",password="password",uid=$(id -u),gid=$(id -g) Doing this manually can quickly become a nuisance, but you can easily automate this task by writing a simple Bash shell script: Since your photo library sits now on the NAS, you need to mount it on your local machine before you can launch digiKam. Congratulations, you are done! Automate Mount and Backup Actions Once you’ve done that, go back to the Settings → Configure digiKam → Collections section and remove the emptied local collections. Move the existing albums into the new collection. Use the Add Collection button next to Collection on Network Shares to add the mounted folder as a new collection, then click OK. In digiKam, choose Settings → Configure digiKam and switch to the Collections section. password password of the specified user.user SMB user name (usually an existing NAS user name)./path/to/local/dir path to the directory on the local machine where you want to mount the remote folder.This is going to be the new location for your photo library. /path/to/dir – path to the directory on the NAS.ipaddress – the actual IP address of the NAS (e.g., 192.168.178.47).Assuming that the SMB server is up and running on the NAS, you can use the following command to mount the desired remote directory into the local folder: sudo mount -t cifs //ipaddress/path/to/dir /path/to/local/dir -o user="user",password="password",uid=$(id -u),gid=$(id -g) Practically all NAS appliances on the market support the SMB protocol, so you can use it to mount a remote directory on your machine. Next step is to mount a remote NAS directory on the local machine storing your photo library. Launch then digiKam, choose Settings → Database Migration and use the migration tool to move the existing digiKam databases to MariaDB. To be on the safe side, back up the digiKam databases first. Now it’s time to switch digiKam to the MariaDB database engine. Enable the Global privileges → Check all option, and press Go. Choose Any host from the Host name drop-down list. Specify the desired user name and password. Switch then to the User Accounts section and create a new user by clicking on Add user account. To do this, launch phpMyAdmin, switch to the Databases section, and create three databases: digikam, digikam-thumbnails, and digikam-recognition. Next step is to create a new database user as well as databases for use with digiKam. To manage the server and databases, install the phpMyAdmin application from the App Center. To do this on a QNAP NAS, launch the Control Panel, click SQL Server in the Applications section, and activate the Enable SQL server and Enable TCP/IP networking options. While many NAS models ship with the MySQL/MariaDB database server, you often need to activate it manually. Keep in mind, though, that if any of your neighbors get the same idea of using powerline adapters on their local networks, this will affect the overall speed of your network too. In that case, a couple of Gigabit powerline network adapters provide a less cumbersome solution. However, laying Ethernet cables around your apartment might not be particularly practical. Even the fastest WiFi connection is simply not fast enough, so a wired network connection is the only viable option here. ![]() First of all, you need a fast network link between the NAS and any machine that you want to use for working with your photo library. Switching to the NAS-based digiKam setup is a three-step process:īefore you proceed, though, you need to do some preparatory work. ![]() This allows you to access your photo library from any machine on the same network as well as keep your photo library safe thanks to the fact that storage on most NAS appliances is usually configured as RAID. ![]() Got a NAS? Still store your photo library and digiKam databases on a local machine? It’s time to take your digiKam setup to the next level by moving your photo library to the NAS and switching to the MariaDB (or MySQL) database backend.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |