0
Answered

Sorry, you are not authorized to access any file on this server 2.0.2

brinkdogg 3 years ago updated by Bryon Brinkmann 3 years ago 10

Was running the latest 1.10 and wanted to try 2.0.2 so I deleted 1.10 and installed 2.0.2. No matter what I get "Sorry, you are not authorized to access any file on this server". Nothing works! What am I missing here..


Ubuntu Server = Ubuntu 16.04 

http:xxx.xxx.xxx.xxx:2202 or 2202/admin same error. 

Answer

Answer
Answered

Brinkdogg, due to heavy changes in 2.0.X, you have to reconfigure Ubooquity as if it were a completely new installation (shared folders, users, etc.).


Let me know if you already did that and still have issues.

Yep,


Today, when upgrading from 1.x to 2.x, there is no migration taking care of the db & settings.

You need to restart everything from scratch, which may lead to your symptoms from my perspective.


Try starting again from a clean working directory (no old db or settings there e.g.)


If like me you find it not convenient, then give a hint to Tom by liking my proposal at the end of post http://ubooquity.userecho.com/topics/489-database-backup-rebuild/#comment-3026 ;-)

Answer
Answered

Brinkdogg, due to heavy changes in 2.0.X, you have to reconfigure Ubooquity as if it were a completely new installation (shared folders, users, etc.).


Let me know if you already did that and still have issues.

So I kinda gave up on the beta so I waited for the final hoping I wouldn't get the same error. But guess what?


Sorry, you are not authorized to access any file on this server

I've used /var/www/html/uboouity ~/ubooquity and much more with no luck. I'm at a loss here


OK - Now i've tried an completely fresh install of ubuntu 16.04 and I use this command to start 

java -jar Ubooquity.jar or sudo java -jar Ubooquity.jar in my home directory. Still get the same above error.  


java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)


I had the same error message, but it went away once I entered / setup the Admin Password.

This message, "Sorry, you are not authorized to access any file on this server", is what Ubooquity displays when it has nothing to show, meaning when no folder has been shared yet, or when the user you are logged in with doesn't have rights on any of the shared folder.


In other word, when you donwload and run Ubooquity with further configuration, you get this message.

I guess I should reword it to be more explicit.


So the fix for your problem is simply to configure Ubooquity again (The documentation has been updated, should you need any help).

This is so odd, I don't even get the chance to configure it. I unzip it to ~/booquity folder cd to the folder start it with one of the below commands. Then go to http://xxx.xxx.xxx.xxx:2202/admin or 2203 ETC. 


I've started it with:

java -jar Ubooquity.jar -remoteadmin 

java -jar Ubooquity.jar -remoteadmin –adminport 2203

java -jar Ubooquity.jar -remoteadmin –adminport 2203 -headless 


This is a ubuntu 16.04 Server. VMware

Hope I'm not being an idiot!

SO I figured it out! The issue is with the preference.json. 


Once I start Ubooquity.jar it creates all the needed file but for some weird ass reason it will not allow to access anything. I shut it down and edited the preference.json to reflect a (below) path to where books live and restarted it.  I was able to access everything. I've also attached my ubooquity.service if anyones interest for it to startup on start



 "booksPaths" : [ {
    "pathString" : "/path/to/where/Books _ Magazines",
    "userName" : [ ]
  }, {
    "pathString" : "/path/to/where/Books _ Ebook",
    "userName" : [ ]
  } ],
"users" : [ ],



*** ubooquity.service***


[Unit]
Description=Ubooquity
After=network.target

[Service]
User=yourusername
WorkingDirectory=/opt/ubooquity2
ExecStart=/usr/bin/java -jar Ubooquity.jar --remoteadmin
Restart=always

[Install]
WantedBy=multi-user.target


Ubooquity needs writing authorization on the files located in its working directory.


Did you happen to launch Ubooquity manually the first time (allowing to create all its files with user A) then as a service (with user B, hence the rights problem) ?

No to your question. - Launched it via the commandline as myself & confirmed the permissions were good for the directory and .jar. Was denied access every time no matter if it was in my home dir, /var/www/html/ubooquity or /opt/ubooquity. Used root a couple of times and still the same issue.  Only worked when I manually added a share.