简体   繁体   中英

How to mount apple Airport Time Capsule with write access on linux Mint20.1?

I recently got a Apple airport time capsule and I am trying to use the disk as a NAS.

The problem I have is that when I mount the disk to a local folder, that the owner of the folder always changes to root. So after mounting, I can see and access the files in the target folder, but it is only readonly. I tried changing the owner of the folder, (sudo chown curruser /home/curruser/airptc), although this doesn't generate any errors it doesn't do anything. So the owner stays root.

When I unmount the disk and then change the owner, it works like normal and the owner is back changed to curruser. After remounting the disk the same thing happens all over again. The command I use to mount is:

sudo mount.cifs //192.168.1.200/nas /home/curruser/airport/ --verbose -o username=airp-account-user,pass=airport-account-passw,sec=ntlm,vers=1.0,gid=$(id -g), uid=$(id -u),forcegid,forceuid, file_mode=0777, dir_mode=0777

I also tried adding rw as parameter, but this doesn't changes anything. When I try to use this mounting command without sudo (in an attempt to avoid the changing of ownership), I get the following error:

mount.cifs: permission denied: no match for /home/curruser/airport found in /etc/fstab

Thanks in advance for the help. It would be great if I could get this thing up and running!

I'm on CentOS 8 and this worked for me:

  • Go to your TC, into Disk, click on Account and create a username and give it a password. Save, then reboot your TC.

  • Once it's restarted, make sure you can ping it from your *nix box.

  • On your *nix box, create a directory where you'd normally mount stuff, ie /mnt/timecapsule .

  • Then try to mount it with this:

     mount -rw -t cifs //IP/username //mnt/timecapsule/ -o username=username,password=password,sec=ntlm,vers=1.0

    which worked for me. If you want it to automount each time you reboot your *nix box, add an entry to your /etc/fstab (but I find that confusing), so I just added a cron task to re-mount at reboot using:

     crontab -e
  • Add into your crontab the whole mount command above.

  • Save and reboot to make sure it re-mounts.

It seems the username and the share in your IP/Destination_folder have to be the same, in your case:

//192.168.1.200/nas <- "nas" is where you put your username because the TC creates that shared folder name when you create the User account via the Disk tab in AirPort utility.

Either change your username to "nas", or change your destination folder to //192.168.1.200/airp-account-user .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM