Jump to content
  • Announcements

    • Allan

      Forum Rules   04/13/2018

      Hello folks! As some things are being fixed, we'll keep you updated. Per hour the Forum Rules don't have a dedicated "Tab", so here is the place that we have our Rules back. New Users Lounge > [READ] - InsanelyMac Forum Rules - The InsanelyMac Staff Team. 
stukey

How do I create AFP mount on AppleTV to get to my Mac's Movie folder?

24 posts in this topic

Recommended Posts

Hi all

 

I've installed the great ATVFiles plugin and can now see the contents of the /Users/frontrow/Movies folder from my AppleTV. What I'd like to do now is set-up an AFP mount in /Users/frontrow/Movies on the AppleTV to redirect to my iMac's Movies folder. Then I can just access all of my movie files without having to copy them to the AppleTV or sync via iTunes. I've managed to set-up an AFP mount but it mounts my entire iMac's HD.

 

I just want the mount to go directly to /Users/myusername/Movies on my iMac! Any ideas how I do this?

 

Also, how can I make the mount persistent between reboots of the AppleTV?

 

This is what I've done so so far...

 

1. SSH to AppleTV

2. Make the OSBoot Volume read-write: sudo mount -o remount,rw /dev/disk0s3 /

3. Mount the AFP share: mount_afp -i afp://iMac.Local/Mac\ HD /Users/frontrow/Movies

 

Many thanks!

 

Stukey

Share this post


Link to post
Share on other sites

i'm not 100% sure of this, but it could possible to use a unix link:

ln -s afp://your.mac.ip/Users/YourShortName/Movies

this command, run on your mac, should deposit a link in your home folder, which you could then ssh to frontrow/Movies on your ATV.

Warning: I have no idea whether this will work, I've only used it for local drives and a hacked ATV Finder.

Share this post


Link to post
Share on other sites

Hi Hazkid

 

Thanks for the idea. Unfortunately it doesn't seem to work. It created the symlink but when you try to access it, you just get "No such file or directory" errors.

 

Anybody else have any ideas about this?

 

Thanks,

 

Stu

Share this post


Link to post
Share on other sites

Guys

 

I also got ATVFiles Plugin and v impressed with all the great stuff going on already after release , Need to get this AFP mount working in the movies folder the XBMC is going to be switched off and the old xbox put to rest.

 

Anyone got anyfutehr with this ? managed to get teh stuff mounted ?

Share this post


Link to post
Share on other sites

I was having the same problem. Since my Movies and TV shows were in /Users/neztik/Movies and /Users/neztik/TV shows. I was unable to afp mount them without mounting the whole drive. So then I decided to do a NFS server on my Windows box and then I can mount -t nfs serverip:/Movies /Users/frontrow/Movies/Movies and so on. So I guess you could just get NFS server working on the OSX and do the same. I have alot of media on my Windows box so I decided to go that route. It is working great. I have 3 NFS shares all mounted in different directorys under /Users/frontrow/Movies and I can stream and play any of them.

 

 

I too am ready to retire my XBMC. Just need a few more things like the ability to play my .img and .iso DVD movies. I am going to throw some 720p content at it later tonight. If anyone wants any more info on the NFS stuff I used in windows let me know.

Share this post


Link to post
Share on other sites

Hi again.

 

I understand that you're running the NFS sever on Windows, so I'll have to figure out how to do that on my iMac... but any chance you can provide info on how you set-up the NFS shares mounted under /Users/frontrow/Movies. From the info I can find on the web, I thought you have to mount NFS shares under /mnt?

 

Thanks!

 

Stu

Share this post


Link to post
Share on other sites

 

Hi. I tried the above but it mounts my iMac's entire 'Mac HD' volume. I just want to be able to see the /Movies folders in my user account on the iMac. I don't want to have to wade through masses of folders from within the ATVFiles plugin.

 

Any other ideas?

 

Thanks!

 

Stu

Share this post


Link to post
Share on other sites

From appleTV I created two directorys off /Users/frontrow/Movies.

 

mkdir /Users/frontrow/Movies/dvr1

mkdir /Users/frontrow/Movies/dvr2

 

mount -t nfs 192.168.1.245:/dvr1 /Users/frontrow/Movies/dvr1

mount -t nfs 192.168.1.245:/dvr2 /Users/frontrow/Movies/dvr2

 

This is how I connect to my NFS drives on Windows box. I am just running a NFS server and allow allow all hosts, read access.

Share this post


Link to post
Share on other sites
Hi. I tried the above but it mounts my iMac's entire 'Mac HD' volume. I just want to be able to see the /Movies folders in my user account on the iMac. I don't want to have to wade through masses of folders from within the ATVFiles plugin.

 

Any other ideas?

 

Thanks!

 

Stu

 

Mount it like this:

 

mount_afp -i afp://joey-imac/Macintosh\ HD /Volumes/imac

 

Then do

 

ln -s /Volumes/imac/whatever /Users/frontrow/afp

 

 

You might be able to do a folder mount with the mount_afp command ... I don't have the capabilites to try it out though as I haven't hacked my atv nor do I have a mac.

Share this post


Link to post
Share on other sites
Hi. I tried the above but it mounts my iMac's entire 'Mac HD' volume. I just want to be able to see the /Movies folders in my user account on the iMac. I don't want to have to wade through masses of folders from within the ATVFiles plugin.

 

You can add arbitrary share points with MacOS Server, or with SharePoint if you're using plain old MacOS.

Share this post


Link to post
Share on other sites

You can mount it using the mount_nfs command.

 

I use

 

mkdir /Users/frontrow/Movies/Remote

 

sudo mount_nfs -P 192.168.1.20:/raid/data/Movies /Users/frontrow/Movies/Remote

 

and it works great, however I can't see the folder (I know its mounted just type mount on terminal and you'll see it) and frontrow can see it but I can't see it in finder. This happens to me at my iMac as well, has anyone come up with a way to make it visible??

Share this post


Link to post
Share on other sites

Hi all,

 

I finally got this working. I just didn't know that you could mount the NFS share under /Users/frontrow/Movies. I though you had to do it under /mnt as per my previous post. Anyway, here's what I did to set-up NFS shares on my iMac and then share the /Movies/ folder and then view it using the ATVFiles plugin on AppleTV:

 

1. Configure NFS shares on host system using NFS Manager. Restart host to make sure shares are active.

 

2. SSH to AppleTV:

ssh -1 frontrow@AppleTV.local

3. Create mount point in /frontrow home directory (in this case, in the Movies folder) called 'iMac'

mkdir /Users/frontrow/Movies/iMac

4. Mount NFS share on 'iMac' mount point on AppleTV:

mount_nfs myhost.local:/Users/username/Movies /Users/frontrow/Movies/iMac

I just need to figure out how to make the NFS mount permanent, e.g. so that is remains between reboots of the AppleTV. Any ideas?

 

Thanks,

 

Stu

Share this post


Link to post
Share on other sites

Would someone please help me, I followed the directions on the page but i keep getting this error

mount_nfs: can't get net id for host

What am i doing wrong

Share this post


Link to post
Share on other sites

I need some help here... I setup my AppleTV to show the contents of my iMac's hard drive when I go into the "Files" section. Instead I would like for it to access a firewire drive that is connected to my iMac that contains several video files. I cannot figure out how to remove the link to the iMac drive and have it connect to something else. It is also not showing me the video files that are on the AppleTV inside the Movies folder since I did this.

Share this post


Link to post
Share on other sites
I need some help here... I setup my AppleTV to show the contents of my iMac's hard drive when I go into the "Files" section. Instead I would like for it to access a firewire drive that is connected to my iMac that contains several video files. I cannot figure out how to remove the link to the iMac drive and have it connect to something else. It is also not showing me the video files that are on the AppleTV inside the Movies folder since I did this.

 

Hi eshaheen

 

1. To unmount your existing mount point, use the umount command. So for example, if you used /Users/frontrow/Movies as your mount-point, you would need to use the following command in the terminal (assuming you've already opened an ssh connection to your AppleTV):

 

umount /Users/frontrow/Movies

 

2. With regards to the ATVFiles plugin not showing the contents of your AppleTV's local /Movies folder since creating your AFP mount, it sounds as if you've set /Users/frontrow/Movies as your actual mount-point for your AFP share on your iMac. This means that /Movies will always redirect to your share until either you unmount the share (using the approach outlined in step 1 above) or reboot your AppleTV. I suggest that you create a sub-dir in /Users/frontrow/Movies on the AppleTV and then mount your AFP share point to the sub-dir. That way, you can still access the local files on your AppleTV and your files on the remote share. For example you could create an 'iMac' sub-folder under /Movies like so:

 

mkdir /Users/frontrow/Movies/iMac

 

And then create your mount point to your AFP or NFS share to /Users/frontrow/Movies/iMac instead of /Users/frontrow/Movies

 

3. I think you can set the mount point to your iMac's external firewire drive by referencing the drive name of the external drive instead of your iMac's internal HDD name. At least this seems to work with NFS shares (e.g. mount_nfs iMac.local:/Volumes/ExternalHDD/Movies /Users/frontrow/Movies/iMac)

 

Hope this helps.... I'm just learning about all this stuff myself!

 

Cheers,

 

Stu

 

Would someone please help me, I followed the directions on the page but i keep getting this error

mount_nfs: can't get net id for host

What am i doing wrong

 

Hi mei123!

 

Not sure what "can't get net ID for host" means. I pretty new to all this myself. Maybe somebody with more UNIX experience can advise. Are you using the host name or IP address in your mount_nfs command? Maybe the command can't resolve the host name to the IP address. Try using the IP address instead of the host name and also make sure that you've set-up the NFS shares on your target system correctly. Might be worth trying to ping your target system from the AppleTV to check name/address resolution.

 

Cheers,

 

Stu

Share this post


Link to post
Share on other sites
3. I think you can set the mount point to your iMac's external firewire drive by referencing the drive name of the external drive instead of your iMac's internal HDD name. At least this seems to work with NFS shares (e.g. mount_nfs iMac.local:/Volumes/ExternalHDD/Movies /Users/frontrow/Movies/iMac)

 

Thanks - this really helped. I have now been able to unmount the share points I do not want. My new problem is getting it to mount the external drive... I entered the command below, but get an error at the end.

 

mount_afp -i afp://Eric-Shaheens-Core-2-Duo-iMac.local:/Volumes/mylife /Users/frontrow/Movies/iMac/

 

mount_afp: AFPMountURL returned error -5019, errno is 2

 

Any ideas where I am going wrong?

 

Thanks - this really helped. I have now been able to unmount the share points I do not want. My new problem is getting it to mount the external drive... I entered the command below, but get an error at the end.

 

mount_afp -i afp://Eric-Shaheens-Core-2-Duo-iMac.local:/Volumes/mylife /Users/frontrow/Movies/iMac/

 

mount_afp: AFPMountURL returned error -5019, errno is 2

 

Any ideas where I am going wrong?

 

Update... If I enter:

mount_afp afp://username:password@ip/iMac/ ~frontrow/Movies/iMac

It mounts my iMacs internal hard drive without problems

 

However, If I enter:

mount_afp afp://username:password@ip/Volumes/media ~frontrow/Movies/iMac

I get the following message:

mount_afp: AFPMountURL returned error -5019, errno is 2

 

Any help is really appreciated!

 

Thanks - this really helped. I have now been able to unmount the share points I do not want. My new problem is getting it to mount the external drive... I entered the command below, but get an error at the end.

 

mount_afp -i afp://Eric-Shaheens-Core-2-Duo-iMac.local:/Volumes/mylife /Users/frontrow/Movies/iMac/

 

mount_afp: AFPMountURL returned error -5019, errno is 2

 

Any ideas where I am going wrong?

 

 

 

Update... If I enter:

mount_afp afp://username:password@ip/iMac/ ~frontrow/Movies/iMac

It mounts my iMacs internal hard drive without problems

 

However, If I enter:

mount_afp afp://username:password@ip/Volumes/media ~frontrow/Movies/iMac

I get the following message:

mount_afp: AFPMountURL returned error -5019, errno is 2

 

Any help is really appreciated!

 

SUCCESS! I got it working with the following command:

mount_afp afp://username:password@iMac.local/mylife ~frontrow/Movies/iMac

 

However, I have another issue... Any video file I choose from my external drive gives me the "No content found" screen on the AppleTV. If I copy the same files over to the AppleTV they work just fine. It shows the file sizes correctly on the ATV, but it shows all videos to be 0:00 in length. Any ideas on this issue?

Share this post


Link to post
Share on other sites

Does anyone know how to mount a specific directory on a disc using the same commands. I would rather not give everyone access to all my other data through my ATV Files interface.

 

Anyone got any ideas?

Share this post


Link to post
Share on other sites
However, I have another issue... Any video file I choose from my external drive gives me the "No content found" screen on the AppleTV. If I copy the same files over to the AppleTV they work just fine. It shows the file sizes correctly on the ATV, but it shows all videos to be 0:00 in length. Any ideas on this issue?

 

I have the exact same problem. I can navigate my afp volume, selecting any folder and file, but I see correct file sizes and 0:00 length. And selecting the videos (or even plain mp3s) for playback gives me a "No content found". Those same files copied over to the AppleTV work fine.

 

The disk is Airport Disk hanging off a new Airport Extreme base station, if it matters. I have it mounted on the atv as ~/Movies/ext. I tested copying a file from ~/Movies/ext to ~/Movies and it worked fine (verifies I have appropriate read permissions. File plays fine in ~/Movies, but not in the ~/Movies/ext folder.

 

Any ideas?

Share this post


Link to post
Share on other sites

FYI: My problem went away when I upgraded from 0.2.1 to 0.2.2. Now I can play video/audio off a remote AFP share without any problem. Now my only problems is that I wasted my time and money upgrading the hard drive in the AppleTV ;)

Share this post


Link to post
Share on other sites
FYI: My problem went away when I upgraded from 0.2.1 to 0.2.2. Now I can play video/audio off a remote AFP share without any problem. Now my only problems is that I wasted my time and money upgrading the hard drive in the AppleTV :D

 

I upgraded to 0.2.2 and I still cannot play files off an AFP mount...

Share this post


Link to post
Share on other sites

Hi. I am having problems getting a harddrive to mount so the appletv can see it. I'm a total newbie with this stuff but so far I have the appletv hacked with the patchstick and installed nitotv and perian and the kext loader. My setup is a macmini with a bare hfs journed usb drive attached that I add .avi files to that are recorded from a eyetv 200 .recorder. I can copy files over with fugu and see them but I want to be able to stream them from the external drive. When I turn on personal file sharing on the mni the the appletv sees my computer under nitotv and sapphire but the file doesn't have anything in it. Is there a easy way to stream .avi files to the appletv from the external? A step by step would be great if anyone has got this to work.

 

thank you very much.

Share this post


Link to post
Share on other sites

i cannot make my osx to share my files to my apple tv ( i'm trying since 6 days ago )

 

please help me

 

mount_afp: The mountpoint: /Users/frontrow/Movies/iMac does not exist, stat returns 2

-bash-2.05b$ mount_afp afp://username:password@iMac.local/mylife ~frontrow/Movies/

mount_afp: the mount flags are 0000 the altflags are 0020

mount_afp: AFPMountURL returned error -1069, errno is -1069

-bash-2.05b$ mount_afp afp://username:password@iMac.local/tiger ~frontrow/Movies/

mount_afp: the mount flags are 0000 the altflags are 0020

^[[Amount_afp: AFPMountURL returned error -1069, errno is -1069

-bash-2.05b$ mount_afp afp://T T:a@192.168.1.3/tiger ~frontrow/Movies/mount_afp: the mount flags are 0000 the altflags are 0020

mount_afp: AFPMountURL returned error 22, errno is 2

-bash-2.05b$ mount_afp afp://tt:a@192.168.1.3/tiger ~frontrow/Movies/

mount_afp: the mount flags are 0000 the altflags are 0020

mount_afp: AFPMountURL returned error -1069, errno is -1069

-bash-2.05b$ mount_afp afp://tt:a@192.168.1.3/tiger ~frontrow/Movies/

 

i gave this commands throught ssh connection

 

tt is my username

a is my password for the username

192.168.1.3 is my osx ip

tiger is my patrition

~frontrow/movies is my path to apple tv

 

what am i doing wrong ?

 

please i am desperate .

 

i try every command that i could think about it and that i founded on this topik and on awkwardtv.org.

 

thanks.

Share this post


Link to post
Share on other sites

Hi to all

 

I'm just having same problem. I followed instructions, made ln -s and I did it, it works!

 

Now, I'm not able to repeat it. The alias I made was a try of other folder and I wanna change it, but I can't.

 

This is what I wrote when I did it:

-bash-2.05b$ sudo /usr/sbin/diskutil repairPermissions /
Password:
Error detected (-9997) while verifying/repairing permissions disk disk0s3 OSBoot
-bash-2.05b$ mount_afp -i afp://isa:xxxx@PowerMac.local/Videos /Users/frontrow/Movies/Videos
dyld: lazy symbol binding failed: Symbol not found: _realpath$DARWIN_EXTSN
 Referenced from: /sbin/mount_afp
 Expected in: /usr/lib/libSystem.B.dylib

dyld: Symbol not found: _realpath$DARWIN_EXTSN
 Referenced from: /sbin/mount_afp
 Expected in: /usr/lib/libSystem.B.dylib

Trace/BPT trap
-bash-2.05b$ mount_smbfs "//isa:xxxx@192.168.1.2/Videos" ~/Movies/Videos
mount_smbfs(220) malloc: *** vm_allocate(size=3221221376) failed (error code=3)
mount_smbfs(220) malloc: *** error: can't allocate region
mount_smbfs(220) malloc: *** set a breakpoint in szone_error to debug
-bash-2.05b$ mount_afp afp://isa:xxxx@powermac.local/Videos /Users/frontrow/Movies/Videos
dyld: lazy symbol binding failed: Symbol not found: _realpath$DARWIN_EXTSN
 Referenced from: /sbin/mount_afp
 Expected in: /usr/lib/libSystem.B.dylib

dyld: Symbol not found: _realpath$DARWIN_EXTSN
 Referenced from: /sbin/mount_afp
 Expected in: /usr/lib/libSystem.B.dylib

Trace/BPT trap
-bash-2.05b$ ln -s afp://192.168.1.2/Volumes/Videos
-bash-2.05b$ ls
2Z694-5573-24.dmg	Movies			Videos
Applications		Music			atvflash
Documents		Music Playlists		recovery.dmg
Downloads		Pictures
Library			Video Playlists
-bash-2.05b$ cd Videos
-bash: cd: Videos: No such file or directory
-bash-2.05b$ open Videos
2008-12-07 22:07:46.893 open[225] No such file: /mnt/Scratch/Users/frontrow/Videos
-bash-2.05b$ ls
2Z694-5573-24.dmg	Movies			Videos
Applications		Music			atvflash
Documents		Music Playlists		recovery.dmg
Downloads		Pictures
Library			Video Playlists
-bash-2.05b$ sudo mv ~/Videos ~/Movies/
Password:
mv: rename /Users/frontrow/Videos to /Users/frontrow/Movies/Videos: Is a directory
-bash-2.05b$ sudo mv ~/Videos Users/frontrow/Movies/
mv: rename /Users/frontrow/Videos to Users/frontrow/Movies/: No such file or directory

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Recently Browsing   0 members

    No registered users viewing this page.

×