(Solved)I cannot access my dolibarr from another computer

Hi, what seems the problem, I cannot access my dolibarr from another computer…

169.254.21x.xxx - - [27/Mar/2021:04:34:24 -0400] “GET /localhost/dolibarr HTTP/1.1” 404 493 “-” “Mozilla/5.0 (X11; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0”
169.254.21x.xxx - - [27/Mar/2021:04:43:10 -0400] “GET /localhost/dolibarr/index HTTP/1.1” 404 494 “-” “Mozilla/5.0 (X11; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0”
169.254.21x.xx - - [27/Mar/2021:04:43:10 -0400] “GET /favicon.ico HTTP/1.1” 404 493 “http://169.254.xxx.xxx/localhost/dolibarr/index” “Mozilla/5.0 (X11; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0”
169.254.21x.xxx - - [27/Mar/2021:04:43:49 -0400] “GET /localhost/dolibarr/index.php HTTP/1.1” 404 494 “-” “Mozilla/5.0 (X11; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0”
169.254.21x.xxx - - [27/Mar/2021:04:43:49 -0400] “GET /favicon.ico HTTP/1.1” 404 493 “http://169.254.xxx.xxx/localhost/dolibarr/index.php” “Mozilla/5.0 (X11; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0”
169.254.xxx.xxx - - [27/Mar/2021:04:53:04 -0400] “GET /localhost/dolibarr/index.php HTTP/1.1” 404 494 “-” “Mozilla/5.0 (X11; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0”
169.254.21x.xxx - - [27/Mar/2021:04:53:27 -0400] “GET /localhost/dolibarr/index.php HTTP/1.1” 404 494 “-” “Mozilla/5.0 (X11; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0”

It says below

Not Found

The requested URL was not found on this server.

Apache/2.4.38 (Debian) Server at 169.254.xxx.xxx Port 80

Hi,

How do you install dolibarr ?

Hi ksar, thanks for your reply; I installed using the steps here Dolibarr for Ubuntu or Debian - Dolibarr ERP CRM Wiki

and I also tried this How to Install LAMP Stack on Ubuntu 20.04 Server/Desktop - LinuxBabe

but have no luck

here is my network settings…

COMPUTER A (server)
Screenshot from 2021-03-29 04-09-03 Screenshot from 2021-03-29 04-20-19

COMPUTER B (client)
Screenshot from 2021-03-29 16-19-57 Screenshot from 2021-03-29 16-19-38 Screenshot from 2021-03-29 16-12-52

Hello,

On the server computer, what is the address you put in the web browser to access Dolibarr ?
On the client computer, what is the address you put in the web browser to access Dolibarr ?

It seems a Vhost issue, could explain what do you put for Apache config and on which folder do you put dolibarr ?

please find the below…

in the client, I put http://169.xxx.xxx.xxx/localhost/dolibarr/index

Hej deploy,

as far as i remember the starting folder for webservices under Ubuntu is /usr/www/html. If you installed Dolibarr in a subfolder Dolibarr (so the whole foldername is /usr/www/html/Dolibarr) the user from another computer may get access to Dolibarr via http://<ip-address of the server, something like 192.168.0.100>/Dolibarr/htdocs. If you use a hoster it would be http://www.your-servername.com/Dolibarr/htdocs.
You mentioned that you added the folder “localhost”. That is just necessary if you call Dolivbarr from the computer where Dolibarr is installed. So you call Dolibarr from the Installserver with http://localhost/Dolibarr/htdocs.
What you have to enter as URL in the browser depends on the computer you are currently working on and on which server you install Dolibarr.

regards
Stefan

Hi Stefan, thanks for your feedback. I tried what you have said but still no result.

Hi ksar,I edited the apache2 conf file and I changed the below from none to all the highlighted.
<Directory /var/www/>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted

Hej deploy,

strange, but there are various possibilities of problems… :blush:

Do you get an error message when you try to access Dolibarr from an other computer ?
Can you ping the server from the other computer ?
Is there a firewall which prevends the server to be accessed ?
You can open Dolibarr via browser from the computer were Dolibarr is installed ? If yes, enter the complete URL in the browser of the other computerand substitute “localhost” with the IP of the server.

regards
Stefan

Hi,

you seem to have an IP address problem. According to your log your Apache listens on 169.254…
This is a fallback IP on an unconfigured or not correctly configured interface. It’s configured for DHCP but does not get an IP.

Please try to fix that and post an updated apache log.

Best regards
Bastian

Hi Bastian,

Thanks for your feedback, I will try to do what you have said and suggestion then will get back to you.

On the other hand, I tried to refreshed and configured my static address in my server and when I tried to ping my server from my client, it is unreachable.

Hi Deploy, i’ve been reading this thread and i think that you must to check first a couple of fits, that i must do when i have the trouble you have:

  • You must be able to do a PING from the client machine to the server machine: ping 192.169.XXX.XXX
  • Then, you must be able to get SIMPLY AN STATIC FILE (like an image) from the server on your browser: http://192.169.XXX.XXX/image.png (for example)

Usually the problem you have is regarding these 2 fits. Sometimes is a firewall or network issue, and sometimes is a bad Apache miss-configuration. Once you see the image.png you probably wil be able to make accessible Dolibarr (although obviously can be also other issues in the Dolibarr installation).

Last tip

During more than 15 years developing i like to configure my local Apache server and virtualhosts in this way, that i recommend to you:

  sudo nano /etc/apache2/sites-available/te.me.conf                                      
<VirtualHost *:80>
        DocumentRoot /home/sergi/www/te.me
        ServerName te.me
        ServerAlias www.te.me
        <Directory "/home/sergi/www/te.me">
                Options Indexes FollowSymLinks MultiViews
                AllowOverride All
                Require all granted
        </Directory>
        UseCanonicalName off
</VirtualHost>
<IfModule mod_ssl.c>
    <VirtualHost *:443>
        DocumentRoot /home/sergi/www/te.me
        ServerName te.me
        ServerAlias www.te.me
        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined
        SSLEngine on
        SSLCertificateFile /etc/apache2/ssl/apache.crt
        SSLCertificateKeyFile /etc/apache2/ssl/apache.key
        <FilesMatch "\.(cgi|shtml|phtml|php)$">
                SSLOptions +StdEnvVars
        </FilesMatch>
        <Directory "/home/sergi/www/te.me">
                SSLOptions +StdEnvVars
                Options Indexes FollowSymLinks MultiViews
                AllowOverride All
                Require all granted
        </Directory>
    </VirtualHost>
</IfModule>

In this way i’m able to call my site from browser using something more “human redeable” like:

  • https://te.me/index.php?.....

You need to do only another configuration in each machine trying to access this “home domain name”: add this line to your /etc/hosts file (in linux) or c://windows/system32/drivers/… /hosts (in win10):

127.0.1.1 te.me

Well, in the SAME MACHINE on you have installed the Apache, you must put the address 127.0.0.1 but in other machines of the LAN/WAN you must put the IP of the server to them, like: 192.168.0.5.

Cheers!

Hi Caos30 and Bastian,

Whats is this error? I just checked it with my error log.
[Thu Apr 01 00:00:48.250415 2021] [mpm_prefork:notice] [pid 2620] AH00163: Apache/2.4.38 (Debian) configured – resuming normal operations
[Thu Apr 01 00:00:48.250496 2021] [core:notice] [pid 2620] AH00094: Command line: '/usr/sbin/apache2’
[Thu Apr 01 00:31:31.645502 2021] [mpm_prefork:notice] [pid 2620] AH00169: caught SIGTERM, shutting down
PHP Warning: Module ‘intl’ already loaded in Unknown on line 0
[Thu Apr 01 00:31:31.853307 2021] [mpm_prefork:notice] [pid 3132] AH00163: Apache/2.4.38 (Debian) configured – resuming normal operations
[Thu Apr 01 00:31:31.853519 2021] [core:notice] [pid 3132] AH00094: Command line: '/usr/sbin/apache2’

here is my apache2.conf

DefaultRuntimeDir ${APACHE_RUN_DIR}
PidFile ${APACHE_PID_FILE}
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 5
User ${APACHE_RUN_USER}
Group ${APACHE_RUN_GROUP}
HostnameLookups Off
ErrorLog ${APACHE_LOG_DIR}/error.log
LogLevel warn
IncludeOptional mods-enabled/.load
IncludeOptional mods-enabled/
.conf
Include ports.conf

Options FollowSymLinks
AllowOverride None
Require all denied

<Directory /usr/share>
AllowOverride None
Require all granted

<Directory /var/www/>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted

#<Directory /srv/>

Options Indexes FollowSymLinks

AllowOverride None

Require all granted

#

AccessFileName .htaccess
<FilesMatch “^.ht”>
Require all denied

LogFormat “%v:%p %h %l %u %t "%r" %>s %O "%{Referer}i" "%{User-Agent}i"” vhost_combined
LogFormat “%h %l %u %t "%r" %>s %O "%{Referer}i" "%{User-Agent}i"” combined
LogFormat “%h %l %u %t "%r" %>s %O” common
LogFormat “%{Referer}i → %U” referer
LogFormat “%{User-agent}i” agent
IncludeOptional conf-enabled/.conf
IncludeOptional sites-enabled/
.conf

my ports.conf
Listen 80

Listen 443 Listen 443

UPDATE:

Currently, I managed to configure my network with static ip correctly mainly because I can be able to ping my server from my client and from my server to my client(vice versa)

Now, still I can’t access my dolibarr in my server. It says…

Unable to connect
Firefox can’t establish a connection to the server at 192.xxx.xxx.xxx.
The site could be temporarily unavailable or too busy. Try again in a few moments.
If you are unable to load any pages, check your computer’s network connection.
If your computer or network is protected by a firewall or proxy, make sure that Firefox Developer Edition is permitted to access the Web.

I tried many url from my client but nothing happens

https://192.xxx.xxx.xxx/127.0.0.1/dolibarr/htdocs
https://192.xxx.xxx.xxx/127.0.0.1/dolibarr/index.php
https://192.xxx.xxx.xxx/localhost/dolibarr/index.php
https://192.xxx.xxx.xxx/localhost:80/dolibarr/index.php
https://192.xxx.xxx.xxx/localhost/dolibarr/index.php

I tried this https://192.xxx.xxx.xxx/localhost/var/lib/dolibarr/documents but it says below
The connection has timed out

The server at 192.xxx.xxx.xxx is taking too long to respond.

The site could be temporarily unavailable or too busy. Try again in a few moments.
If you are unable to load any pages, check your computer’s network connection.
If your computer or network is protected by a firewall or proxy, make sure that Firefox Developer Edition is permitted to access the Web.

Hej deploy,

try to access the server without “127.0.0.1” (what very often is just the gateway to the internet) and “localhost” (what is just needed if you try to access Dolibarr from the server).
You should enter something like “http:/192.xx.xx.xx/Dolibarr/htdocs” as URL. Watch the upper and lower case, as i’m not sure whether the system is case-sensitive.

regards
Stefan

1 Like

Hi Stefan,

You’re the man!! http://192.xxx.xxx.xxx/dolibarr/index.php is the KEY…I removed the localhost and got it. Thank you very much.

Also, I really appreciated, Thank you very much guys for all those who gave their feedback and support.(Caos30,Bastian, and Ksar).

Indeed, your full support is highly appreciated. Again thank you very much guys.

Happy here :smiley:

1 Like

For dolibarr community and everybody’s information specifically Linux users(Debian); this might help you. This help me a lot; easy and simple steps.

https://linuxconfig.org/unmanaged-network-solution-on-debian-linux