Need to attach NTFS USB drive for videos to RPi2B with OSMC

I have been running XBMC with RaspBMC on a RPi2 for about 1.5 years now. Works fine.
Now I need to set up a new system for use in the summer house to be used for our grandchildren.
I am considering OpenElec or OSMC as the basic system for this and am leaning towards OSMC since it is the successor to RaspBMC I am using today.

This needs to be using a directly connected USB drive (1TB) containing all of the videos, which is different from at home where the videos reside on my network NAS.
So can OSMC use a USB hard drive formatted as NTFS for both read and write??

The Pi will be connected by WiFi to the local network so I can:

  1. Upload new videos from my Win7 PC via a samba share of the hard drive on the Pi (is this possible)
  2. Use the Yatse Android remote control app on my Samsung phone accessed via the WiFi network.

Furthermore:
Note that due to the limited data allowance on my mobile network Internet access in the summer house I don’t want the OSMC or Kodi to access the Internet through the WiFi connection!
I know that RaspBMC by itself does download updates which could be several hundreds of megabytes and this is not going to work in the summer house since it would consume a lot of the monthly allowance!

Yes NTFS read/write is supported on OSMC.

Keep in mind that if you are trying to power the drive directly from the Pi 2 you will need to enable max_usb_current=1 in config.txt and have a good power adaptor. Not all drives can be successfully powered from a Pi so you may need an external power adaptor for the drive.

Yes to both of those.

To disable internet access the easiest way would be to use a Static IP configuration instead of DHCP and simply set the Default gateway deliberately to an IP address other than your router - eg an address not in use by any device.

You can change how OSMC checks for updates in My OSMC too.

Sam

Thanks for the replies!
It turns out that it was a simple case of installing samba from apt-get install and when I had reconfigured the workgroup to my own in the smb-local.conf file the attached USB drive was shared by its label name when I restarted OSMC.
Much simpler than anticipated! :smile:

Now I will have to find the way to switch off auto-updates, I guess I have to reconnect the unit to the TV in order to do that?
It would be nice to have an OSMC configuration file possible to edit with nano instead of going the GUI way in the living room…

Keep in mind that this is a MediaCenter OS - the whole point of it is to provide a 10ft experience that is controlled using a GUI and a remote, so that is where the user interface design has been focused.

It’s also generally assumed that those that want to go out of their way to configure and tweak the system via the command line (a small minority) are power users who will be able to figure out how to do so mostly on their own, perhaps with a small bump in the right direction.

The preferences for the Update GUI are stored in an xml file somewhere so are theoretically possible to change from the command line but it really wouldn’t be worth the effort compared to plugging it into a screen for a minute or two and pressing a few buttons.

OK fair enough…
I just want to make 100% sure that OSMC does not go out on the Internet while I am out in the summer house running on mobile broadband with a limited monthly quota. Updating an operating system in the background is one of the things that can cause me to lose Internet for the rest of the month…
And I need to have it connected to WiFi because that is the only way I can interact with it in the living room using Yatse remote.

Just do

sudo -s
echo "127.0.0.1 apt.osmc.tv" >> /etc/hosts

to prevent communication with the update server

Ok, thanks.
I moved the Pi to the living room after installing the hard drive and filling it with videos to see how it turned out.
I also took the opportunity to set OSMC to never do updates automatically (done in the GUI).
I might take you up on the hosts file later.

Right now I am struggling with getting the OpenVPN server working…

This will not stop Kodi updating addons in the background nor will it stop service addons from potentially using data.

The best way to 100% disable internet access while still allowing local connectivity is to change the default gateway.

I will be using an EdiMax EW-7811 WiFi dongle at the target location.
I have connected once using the WiFi while setting up the system so OSMC knows the login.
How can I change the default gateway once it connects to the network? DHCP will supply the GW address…

Yes, or null route packets by removing the default gateway with ‘route’ or adding a fake route.

Was not clear if OP wanted complete disconnection from WAN.

S

“How can I change the default gateway once it connects to the network? DHCP will supply the GW address…”

Don’t use DHCP. Just enter the same IP address you got from DHCP manually, but with an erroneous gateway - like 10.10.10.10.

It will access anything on your local lan and be accessible by it, but not be able to route any packets further than that.

OK,
I have made an IP reservation the router for the Pi MAC address (will get 192.168.117.136). So that will always be available.
Now when connected via wire and WiFi I opened the OSMC control program in the GUI and went to WiFi where I could see all the numbers filled in. So I just tapped the Configure Manually line and then I kept all of the existing items except the Default gateway, which I set to 192.168.117.2 (the original was on 1).
This made Internet inaccessible as needed! :smile:

Now I only need to figure out how to make the WiFi auto-connect.
When I disable the WiFi adapter for testing via Ethernet and then afterwards enable it again, it does not connect. It just sits there and I have to manually go to the right and select the network it should use and tap (in Yatse) whereupon I get a dialog box for confirmation.
This will work at home where the Pi is using the wired network too so Yatse can reach it, but on the target location there will ONLY be WiFi and then it will be a hen-and-egg situation since Yatse will not be able to connect to OSMC until it has connected WiFi and then noone can confirm the dialog. :frowning:
Is there a setting to tell OSMC to auto-connect to the selected WiFi SSID?

Wifi will not auto connect when Ethernet is already connected.

Unplug the Ethernet cable and Wifi will automatically connect.

Will it connect to the last used WiFi or will it be by random?
If I have connected to two networks during setup, how can I make it forget one of them (only leaving the one that will be present on the end location)?

PS: Regarding the forum, how can I mark a word or sentence to be underlined?
There seems only to be bold and italic available in the reply editor… DS

I think (but am not sure) that if multiple saved networks are available at once it will prefer the most recently connected one.

However if you have two saved networks but they are at different locations (eg it can’t receive them both at the same time) then it will automatically connect to whichever one it can pick up, no need to forget the other one.

If you do want to forget a network, select the network from the list and choose disconnect and forget instead of just disconnect. I think you can only do this if you’re currently connected to a network.

Now I have moved the system out to the final destination and it connects just fine to the WiFi here.
I have set it to use a specific IP address and the gateway is fake. Works fine. :smile:

But I have another question related to the drive I am using:
I formatted it in Win7 and then copied all the video files (44 GB worth) to it in a folder structure at the top level of teh drive.
Now I discovered that there is a folder named $RECYCLE.BIN, which shows up in OSMC when I navigate for a video file.
How can I get rid of it? In Win7 I am not allowed to since it claims it is owned by System (I think), I have no permissions…
Is there a way to hide it from the OSMC GUI when the user navigates the disk in search for the video to play?
Or can I log in via PuTTY and switch to root (sudo su) and just rm it? Does this have adverse effects on something else?

$RECYCLE.BIN is literally the recycle bin for that drive - windows creates it automatically on all drives it formats however the folder is hidden on Windows but is visible in Linux. If it bothers you it should be safe to remove it via ssh.

BTW sounds like you are not making use of the Library ? If your media is mainly Movies/TV Shows then it would probably have been better to scan those files into the Library so that you have full meta-data available, and a nice easy to navigate list of Movies/TV Shows etc with descriptions and fanart. (The Library would also not display the $RECYCLE.BIN folder)

If you’re now at the location with no internet connection it’s too late to scan the library though.

Too late to use library now since he’s at the final location and doesn’t wish to grant web access. No way to scrape like this, unless he happens to have .nfo files already created.

The videos are basically recorded children’s programs from Swedish operator SVT.
I have recorded and then converted them to MP4 using Handbrake.
I have wondered why people on this and the Kodi forums so often refer to the “library”, because it is always empty when I look there. And they talk about something called “scraping” or similar too in this context. I never understood that.
I have only four sources of videos:

  1. Those I record myself on my Samsung phone (grandchildren mostly)

  2. Those I record off the air when the channels send the programs. These I have to convert to MP4 to get into a format suitable for showing by my Daughter’s PlayStation

  3. TV shows in direct view via the play services offered by various channels. This is disabled on this particular installation because of the limited data allowed by my mobile broadband account out here. But on my RaspBMC installation back home where I have fiber this is also used now and then.

  4. I have also bought a children’s programs DVD, which I converted to an MP4 file, so it also can be viewed off the hard disk.

Am I using the OSMC unit wrong, perhaps?