NextPVR Forums
  • ______
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public NextPVR Support Linux v
« Previous 1 … 8 9 10 11 12 … 34 Next »
Moving NextPVR to new system (linux)

 
  • 0 Vote(s) - 0 Average
Moving NextPVR to new system (linux)
mvallevand
Online

Posting Freak

Ontario Canada
Posts: 52,768
Threads: 954
Joined: May 2006
#11
2023-01-07, 10:08 PM
Did you follow the steps on the wiki to create the softlinks?

Martin
cyber
Offline

Junior Member

UK
Posts: 12
Threads: 1
Joined: Jan 2022
#12
2023-01-08, 09:54 AM
Yes I have, I wasn't quite sure where to run it, I ran both of these commands in /opt/nextpvr/system/

Code:
ln -s runtimes/linux-x64/native/libe_sqlite3.so
ln -s runtimes/linux-x64/native/libSkiaSharp.so

I can see a link to libe_sqlite3.so and libSkiaSharp.so in that folder.

I'm moving from RaspberryPi OS (32bit) to Debian (64bit - Intel) if that matters?
mvallevand
Online

Posting Freak

Ontario Canada
Posts: 52,768
Threads: 954
Joined: May 2006
#13
2023-01-08, 03:37 PM (This post was last modified: 2023-01-08, 03:38 PM by mvallevand.)
Sorry I messed up, I was supporting by phone and didn't read the message. Looking at the code the merge is for a different purpose. I wrote all of this with no user input and I messed up my uses cases.

Import will work, but for this, your best bet is a simple sqlite3 replace something like this (untested)

sqlite3 npv43.db3

update scheduled_recording set filename = replace(filename,'/mnt/MyPassport/', '/mnt/data/');

Martin
cyber
Offline

Junior Member

UK
Posts: 12
Threads: 1
Joined: Jan 2022
#14
2023-01-08, 06:25 PM
Is that 2 commands - enter one after another in the terminal?

(2023-01-08, 03:37 PM)mvallevand Wrote: sqlite3 npv43.db3

update scheduled_recording set  filename = replace(filename,'/mnt/MyPassport/', '/mnt/data/');

Should the first command be sqlite3 npvr.db3 rather than sqlite3 npv43.db3?
mvallevand
Online

Posting Freak

Ontario Canada
Posts: 52,768
Threads: 954
Joined: May 2006
#15
2023-01-08, 06:27 PM (This post was last modified: 2023-01-08, 06:27 PM by mvallevand.)
Use the sqlite3 command (with the correct db name of course) Also sudo -u nextpvr sqlite3 ...

Then the second command is entered on the sqlite3 command line.

Then .exit to leave.

Martin
cyber
Offline

Junior Member

UK
Posts: 12
Threads: 1
Joined: Jan 2022
#16
2023-01-10, 09:50 PM
The sqlite3 command (sudo -u nextpvr sqlite3 npvr.db3 and the replace) doesn't seem to do anything when I enter it. The date modified on npvr.db3 remains unchanged.

I tried to start nextpvr as well, the links to download any recordings are broken so it hasn't updated them.
mvallevand
Online

Posting Freak

Ontario Canada
Posts: 52,768
Threads: 954
Joined: May 2006
#17
2023-01-10, 09:58 PM
When you are in sqlite3 when you enter this

select filename from scheduled_recording;

do they begin with /mnt/MyPassport

Martin
cyber
Offline

Junior Member

UK
Posts: 12
Threads: 1
Joined: Jan 2022
#18
2023-01-15, 04:04 PM
Thanks, I realised I had a typo in the path which was causing the issue.

For reference if anyone else wants to do this, here's a short guide with the steps I followed assuming the old recordings path is '/old/path/to/recordings/' and the new path is '/new/path/to/recordings/'. Remember to backup files before touching them. (I'm fairly inexperienced at linux so there may be better ways to do some of these!)

Code:
On both the old and new systems:
sudo service nextpvr-server stop (Stops nextpvr)
sudo service nextpvr-server status (Optional but to check if the service has stopped)

On the old system:

sudo rsync -rav /old/path/to/recordings/ /external/usb/drive/recordings/ (copies recordings to USB drive/recordings)
cd /var/opt/nextpvr/
sudo rsync -rav npvr.db3 /external/usb/drive/ (copies npvr3.db3 to USB drive)
sudo rsync -rav config.xml /external/usb/drive/ (copies config.xml to USB drive)

Plug the external USB drive into the new system.

On the new system (I had permissions issues on transferring config and npvr.db3 so edited them on the desktop):

sudo rsync -rav /external/usb/drive/recordings/ /new/path/to/recordings/ (copies recordings to new location)
sudo rsync -rav /external/usb/drive/config.xml ~/Desktop/ (copies config.xml to Desktop)
sudo rsync -rav /external/usb/drive/npvr.db3  ~/Desktop/ (copies npvr3.db3 to Desktop)


(edit config.xml on Desktop with the following)
nano ~/Desktop/config.xml
    <AutoRemoveMissingRecordings>false</AutoRemoveMissingRecordings>
    <CheckForRenamedRecordings>false</CheckForRenamedRecordings>
    <NoRemoveWhenTreeMissing>true</NoRemoveWhenTreeMissing>
    (Ctrl-x to exit and save)

sudo apt install sqlite3
sqlite3 ~/Desktop/npvr.db3
    (enter the following on the sqlite3 command line)
    update scheduled_recording set filename = replace(filename,'/old/path/to/recordings/', '/new/path/to/recordings/');
    .exit

(back on to the main terminal window)

sudo rm /var/opt/nextpvr/npvr.db3 /var/opt/nextpvr/config.xml (remove the default files on the system, I had no reason to back them up because it was a clean install but you may want to)
sudo mv ~/Desktop/npvr.db3 /var/opt/nextpvr/ (move npvr3.db3 to correct location)
sudo mv ~/Desktop/config.xml /var/opt/nextpvr/ (move config.xml to correct location)
cd /var/opt/nextpvr/
sudo chown nextpvr:nextpvr npvr.db3 config.xml (change user/group to nextpvr)
sudo service nextpvr-server start (to start nextpvr)


Thanks again for the help mvallevand
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)

Pages (2): « Previous 1 2


Possibly Related Threads…
Thread Author Replies Views Last Post
  Linux Command Line To Initiate SchedulesDirect EPG Update LinuxDVR 1 153 2025-04-13, 06:35 PM
Last Post: mvallevand
  NextPVR can't open RAI (Italian main TV channels) links f2fg 17 2,894 2025-03-29, 10:15 AM
Last Post: alice_anto
  Linux install failed -- permission denied? FrogFan 4 391 2025-03-26, 12:39 AM
Last Post: FrogFan
  Guide data issue using NextPVR in a Proxmox LXC njc 10 777 2025-03-23, 01:40 PM
Last Post: njc
  NextPVR oddly limited to 7 tuners DaVinylSmith 4 392 2025-02-12, 02:49 PM
Last Post: DaVinylSmith
  NextPVR webserver not starting, prevents client from starting homemaisonbaile 28 1,172 2025-02-04, 05:23 PM
Last Post: mvallevand
  Is there a 'recommended' version/release of Linux? Bobthegoldfish 1 353 2024-12-24, 12:28 AM
Last Post: mvallevand
  NextPVR 7 looses recordings after post processing ballfam 15 812 2024-12-20, 03:23 AM
Last Post: ballfam
  Colossus 2 and nextpvr Iriman 53 4,406 2024-12-16, 02:32 AM
Last Post: ehfortin
  NextPVR user1232 1 283 2024-11-09, 11:21 AM
Last Post: mvallevand

  • View a Printable Version
  • Subscribe to this thread
Forum Jump:

© Designed by D&D, modified by NextPVR - Powered by MyBB

Linear Mode
Threaded Mode