Can't get the browser page asking for administrator login and password

Hello,

I am a newbie to ERPnext. Planning to use it for my employer, so decided on a test run on my own laptop running debian 8.0 (jessie). Following are the steps I followed.

wget https://raw.githubusercontent.com/frappe/bench/master/install_scripts/setup_frappe.sh
sudo bash setup_frappe.sh --setup-production
sudo bench update

The last step above is perhaps not required on the production branch.

All the steps completed without any error messages. I have a file with plaintext passwords for Frappe, MariaDB and Administrator in the home directory of root user. A directory “frappe-bench” now exists in the home directory of the user who installed frappe using sudo privilege.

As far as I can tell from the documentation, the next step should be to open “127.0.0.1/desk” in the browser and go about setting up ERPnext. However, I get

Not Permitted
You are not permitted to access this page.
Login

If I click on the login link, I get three separate options: (1) to enter email id and password, (2) to enter full name and email id or (3) to enter mail id and click on a “send password” button.

Is this expected behaviour? I was hoping to get a login page for the Administrator with an option to enter the password.

I also tried “127.0.0.1:8000” in the browser address bar. In this case, I get
“./127.0.0.1/site_config.json does not exist”

On trying “127.0.0.1:9000” in the address bar, I get
“Error: ENOENT, stat ‘/home/user/frappe-bench/index.html’ at Error (native)”

Is there something in $HOME/frappe-bench/sites that I should be checking? Any help in troubleshooting appreciated.

Thanks,
arvind

Hello all,

Apologies for the previous half-baked post, I missed reporting some steps. Following is the sequence of commands on a debian 8.0 laptop.

wget https://raw.githubusercontent.com/frappe/bench/master/install_scripts/setup_frappe.sh
sudo bash setup_frappe.sh --setup-production
sudo bench update
bench get-app erpnext https://github.com/frappe/erpnex

It informed that app ‘erpnext’ was already installed.

Next, I issued the commands

bench --site testsite install-app erpnext
bench start

This is what I get after the last command

00:22:57 system | watch.1 started (pid=2978)
00:22:57 system | async_worker.1 started (pid=2976)
00:22:57 system | redis_socketio.1 started (pid=2970)
00:22:57 system | redis_cache.1 started (pid=2979)
00:22:57 system | socketio.1 started (pid=2982)
00:22:57 redis_socketio.1 | [2985] 24 May 00:22:57.825 # Creating Server TCP listening socket 127.0.0.1:12000: bind: Address already in use
00:22:57 redis_cache.1 | [2991] 24 May 00:22:57.825 # Creating Server TCP listening socket 127.0.0.1:13000: bind: Address already in use
00:22:57 system | redis_cache.1 stopped (rc=1)
00:22:57 system | redis_socketio.1 stopped (rc=1)
00:22:57 system | workerbeat.1 started (pid=2977)
00:22:57 system | worker.1 started (pid=2981)
00:22:57 system | longjob_worker.1 started (pid=2980)
00:22:57 system | redis_queue.1 started (pid=2983)
00:22:57 system | web.1 started (pid=2974)
00:22:57 system | sending SIGTERM to workerbeat.1 (pid 2977)
00:22:57 system | sending SIGTERM to watch.1 (pid 2978)
00:22:57 system | sending SIGTERM to redis_queue.1 (pid 2983)
00:22:57 system | sending SIGTERM to web.1 (pid 2974)
00:22:57 system | sending SIGTERM to async_worker.1 (pid 2976)
00:22:57 system | sending SIGTERM to socketio.1 (pid 2982)
00:22:57 system | sending SIGTERM to worker.1 (pid 2981)
00:22:57 system | sending SIGTERM to longjob_worker.1 (pid 2980)
00:22:57 system | watch.1 stopped (rc=-15)
00:22:57 system | async_worker.1 stopped (rc=-15)
00:22:57 system | socketio.1 stopped (rc=-15)
00:22:57 system | web.1 stopped (rc=-15)
00:22:57 system | worker.1 stopped (rc=-15)
00:22:57 system | longjob_worker.1 stopped (rc=-15)
00:22:57 system | redis_queue.1 stopped (rc=-15)
00:22:57 system | workerbeat.1 stopped (rc=-15)

Next, when I try “http://localhost:8000” in the browser, I get
“./localhost/site_config.json does not exist”

Thanks for any help.

arvind

The second problem appears because you are trying to start frappe while he is working,
You have to stop it before, you can stop supervisor or kill frappe process

About the first issue if you want to reset the administrator password use the following command

bench --site SITE_NAME set-admin-password NEW_PASSWORD

Thanks Mustafa.

I am not sure I understood your answer. This is what I tried, after reading your response:

sudo systemctl stop nginx.service supervisor.service

After the above command, “ps aux” confirms that neither “supervisor” nor “nginx” nor “frappe” process are running (and I can confirm that all of them were running before I stopped them using the above command).

After that, if I issue

bench start

I get

03:05:32 system | redis_socketio.1 started (pid=6410)
03:05:32 redis_socketio.1 | [6424] 24 May 03:05:32.860 # Creating Server TCP listening socket 127.0.0.1:12000: bind: Address already in use
03:05:32 system | redis_socketio.1 stopped (rc=1)
03:05:32 system | watch.1 started (pid=6414)
03:05:32 system | workerbeat.1 started (pid=6412)
03:05:32 system | web.1 started (pid=6419)
03:05:32 system | async_worker.1 started (pid=6418)
03:05:32 system | redis_cache.1 started (pid=6421)
03:05:32 system | redis_queue.1 started (pid=6423)
03:05:32 redis_queue.1 | [6438] 24 May 03:05:32.877 # Creating Server TCP listening socket 127.0.0.1:11000: bind: Address already in use
03:05:32 system | socketio.1 started (pid=6426)
03:05:32 system | redis_queue.1 stopped (rc=1)
03:05:32 redis_cache.1 | [6436] 24 May 03:05:32.880 # Creating Server TCP listening socket 127.0.0.1:13000: bind: Address already in use
03:05:32 system | redis_cache.1 stopped (rc=1)
03:05:32 system | longjob_worker.1 started (pid=6425)
03:05:32 system | worker.1 started (pid=6420)
03:05:32 system | sending SIGTERM to workerbeat.1 (pid 6412)
03:05:32 system | sending SIGTERM to watch.1 (pid 6414)
03:05:32 system | sending SIGTERM to web.1 (pid 6419)
03:05:32 system | sending SIGTERM to async_worker.1 (pid 6418)
03:05:32 system | sending SIGTERM to socketio.1 (pid 6426)
03:05:32 system | sending SIGTERM to worker.1 (pid 6420)
03:05:32 system | sending SIGTERM to longjob_worker.1 (pid 6425)
03:05:32 system | watch.1 stopped (rc=-15)
03:05:32 system | web.1 stopped (rc=-15)
03:05:32 system | async_worker.1 stopped (rc=-15)
03:05:32 system | longjob_worker.1 stopped (rc=-15)
03:05:32 system | workerbeat.1 stopped (rc=-15)
03:05:32 system | socketio.1 stopped (rc=-15)
03:05:32 system | worker.1 stopped (rc=-15)

If I try

sudo bench start

I get a similar message

03:06:54 system | redis_socketio.1 started (pid=6488)
03:06:54 redis_socketio.1 | [6501] 24 May 03:06:54.522 # Creating Server TCP listening socket 127.0.0.1:12000: bind: Address already in use
03:06:54 system | async_worker.1 started (pid=6495)
03:06:54 system | socketio.1 started (pid=6496)
03:06:54 system | redis_socketio.1 stopped (rc=1)
03:06:54 system | redis_queue.1 started (pid=6498)
03:06:54 system | web.1 started (pid=6493)
03:06:54 system | watch.1 started (pid=6497)
03:06:54 redis_queue.1 | [6512] 24 May 03:06:54.532 # Creating Server TCP listening socket 127.0.0.1:11000: bind: Address already in use
03:06:54 system | redis_queue.1 stopped (rc=1)
03:06:54 system | redis_cache.1 started (pid=6499)
03:06:54 system | workerbeat.1 started (pid=6489)
03:06:54 system | worker.1 started (pid=6503)
03:06:54 system | longjob_worker.1 started (pid=6500)
03:06:54 system | sending SIGTERM to workerbeat.1 (pid 6489)
03:06:54 system | sending SIGTERM to watch.1 (pid 6497)
03:06:54 system | sending SIGTERM to web.1 (pid 6493)
03:06:54 system | sending SIGTERM to async_worker.1 (pid 6495)
03:06:54 system | sending SIGTERM to socketio.1 (pid 6496)
03:06:54 system | sending SIGTERM to redis_cache.1 (pid 6499)
03:06:54 system | sending SIGTERM to worker.1 (pid 6503)
03:06:54 system | sending SIGTERM to longjob_worker.1 (pid 6500)
03:06:54 system | watch.1 stopped (rc=-15)
03:06:54 system | redis_cache.1 stopped (rc=-15)
03:06:54 system | async_worker.1 stopped (rc=-15)
03:06:54 system | worker.1 stopped (rc=-15)
03:06:54 system | workerbeat.1 stopped (rc=-15)
03:06:54 system | socketio.1 stopped (rc=-15)
03:06:54 system | longjob_worker.1 stopped (rc=-15)
03:06:54 system | web.1 stopped (rc=-15)

After either command, “ps aux” shows that neither “frappe” nor “supervisor” nor “nginx” is running. If I try “localhost:8000” or “localhost:80” in a browser, I get “Unable to Connect” message.

If I issue the command

sudo systemctl start nginx.service supervisor.service

then of course “ps aux” shows that “supervisor” and “nginx” and “frappe” are running. Next, if I try “localhost:8000” in a browser, I get the error message previously reported:

Not Found
./localhost/site_config.json does not exist

If I try “localhost:80”, the page is similar to what I reported in my first message above. I get three separate options: (1) to enter email id and password, (2) to enter full name and email id or (3) to enter mail id and click on a “send password” button.

What am I doing wrong? And what should I be doing? This is my first experience with frappe and erpnext, so would appreciate a list of exact commands that I should be trying.

And Mustafa, I could change the password for administrator using the command you suggested, but that isn’t really the problem. This is my problem: In a browser, how do I get the page which will allow me (i.e. the ‘user’ with sudo privilege issuing all of the above mentioned commands) to login as administrator and proceed with setting up erpnext.

Thanks for any assistance.

arvind

Ummm,

Make sure that you have site you can find it at frappe-bench/sites/

Then

bench --site SITE_NAME serve

if you don’t want to write --site argument every time you can use the following

bench use SITE_NAME

This will define SITE_NAME as a default site for you.

bench serve must run successfully or give you a detailed error.
if you have error share it with us.

I guess the problem appears because one of the following:

  • 1- You didn’t choose the site --site
  • 2- You have a site, but you didn’t make it default site.
  • 3- You have problem in your site, so create new site using bench make-site SITE_NAME and make sure the previous command have finished without errors.
1 Like