meganz / MEGAcmd

Command Line Interactive and Scriptable Application to access MEGA
Other
1.92k stars 406 forks source link

Mega.nz not start at boot #710

Open essequadra77 opened 2 years ago

essequadra77 commented 2 years ago

Good afternoon, Sorry for my bad English. I have a QNAP TS-230 and I have installed megacmd from the app store. The version is 1.4.0. After each reboot I have to log in from SSH and manually start the synchronization. How do you automatically start synchronization? I thank you in advance for your help.

jx-mega commented 2 years ago

Hello, please install the latest version of MEGAcmd from our website according to your OS from here: https://mega.nz/megacmd You will be able to schedule your backups by referring to https://github.com/meganz/MEGAcmd/blob/master/contrib/docs/BACKUPS.md

essequadra77 commented 2 years ago

Hi, thanks for your reply. 1.4.0 is the latest version for my NAS (QNAP TS-230). My problem is Megacmd sync not start after reboot of NAS.

The first time, I did this steps:

[~] # export HOME=/share/homes/admin [/root] # export PATH=/share/CACHEDEV1_DATA/.qpkg/MEGAcmd:$PATH [/root] # mega-cmd .==============================================================================. _ \/ ___ / ___ / \ _ \/ \ / / \ / __ ' ` \ / _` /__\ _ / _ \ ( (_ _ _ ____ _// __ _ _ _ _,
Welcome to MEGAcmd! A Command Line Interactive and Scriptable
Application to interact with your MEGA account.
Please write to support@mega.nz if you find any issue or
have any suggestion concerning its functionalities.
Enter "help --non-interactive" to learn how to use MEGAcmd with scripts.
Enter "help" for basic info and a list of available commands.

`==============================================================================´ [Initiating server in background. Log: /share/homes/admin/.megaCmd/megacmdserver.log] MEGA CMD> login s**@gmail.com ***** Enter the code generated by your authentication app: 7*5 Fetching nodes ||########################################||(6/6 MB: 100.00 %) s**@gmail.com:/$ sync /share/CACHEDEV1_DATA/S** /B*/S*** s**@gmail.com:/$

Everything worked perfectly, even after closing the SSH session. After reboot, however, it doesn't work. To make it work I did this steps

[~] # export HOME=/share/homes/admin/ [/root] # export PATH=/share/CACHEDEV1_DATA/.qpkg/MEGAcmd:$PATH [/root] # mega-cmd .==============================================================================. _ \/ ___ / ___ / \ _ \/ \ / / \ / __ ' ` \ / _` /__\ _ / _ \ ( (_ _ _ ____ _// __ _ _ _ _,
Welcome to MEGAcmd! A Command Line Interactive and Scriptable
Application to interact with your MEGA account.
Please write to support@mega.nz if you find any issue or
have any suggestion concerning its functionalities.
Enter "help --non-interactive" to learn how to use MEGAcmd with scripts.
Enter "help" for basic info and a list of available commands.

`==============================================================================´ [Initiating server in background. Log: /share/homes/admin//.megaCmd/megacmdserver.log] Resuming session ... .-----------------------------------------------------------------------------. | Server is still trying to log in. Still, some commands are available. | | Type "help", to list them. | .-----------------------------------------------------------------------------. MEGA CMD>

The session is recovered and everything works fine.

I tried again without changing the path of the HOME, but the result is the same: mega-cmd is not automatically executed at reboot