Discussion:
[Monitorix-general] libpng error: Write Error
czezz
2014-11-27 19:51:26 UTC
Permalink
I have installed Monitorix 3.6 on my old Slackware 12 box.
I have compiled it using SlackBuilds.
For some reason when I start monitorix and access over web browser, no pictures are displayed and I get following error in /var/log/monitorix -  libpng error: Write Error.
libpng is installed with following version: libpng-1.2.50-i486-1_slack12.0
Can anyone please help me out here what is wrong
# cat /var/log/monitorix
Thu Nov 27 20:26:28 2014 - Starting Monitorix version 3.6.0 (pid 2543).
Thu Nov 27 20:26:28 2014 - Loaded main configuration file '/etc/monitorix/monitorix.conf'.
Thu Nov 27 20:26:28 2014 - Initializing graphs.
Thu Nov 27 20:26:29 2014 - fs::fs_init: Unable to detect the device name of '/boot'. I/O stats for this filesystem won't be shown in graph. If this is really a mount point then consider using <devmap> to map it manually to a device name.
Thu Nov 27 20:26:29 2014 - Generating the 'index.html' file.
Thu Nov 27 20:26:29 2014 - WARNING: the built-in HTTP server has authentication disabled.
HTTPServer: You can connect to your server at http://localhost:18080/
Thu Nov 27 20:26:29 2014 - Started built-in HTTP server (pid 2613).
Thu Nov 27 20:26:29 2014 - Ok, ready.
libpng error: Write Error
libpng error: Write Error
libpng error: Write Error
libpng error: Write Error
libpng error: Write Error
libpng error: Write Error
Best regards,
czezz
Bertrand Caplet
2014-11-27 20:06:00 UTC
Permalink
Post by czezz
I have installed Monitorix 3.6 on my old Slackware 12 box.
I have compiled it using SlackBuilds.
For some reason when I start monitorix and access over web browser, no
pictures are displayed and I get following error in /var/log/monitorix
- libpng error: Write Error.
libpng is installed with following version: libpng-1.2.50-i486-1_slack12.0
Can anyone please help me out here what is wrong
Hey Czezz,
It seems you have permissions errors.
where is you root directory of monitorix ?
Who own it ?

see in
<httpd_builtin>
user = nobody
group = nobody
</httpd_builtin>
That's the default.

Regards,
--
CHUNKZ.NET - casual fiddler and computer technician
Bertrand Caplet, Flers (FR)
Feel free to send encrypted/signed messages
Key ID: FF395BD9
GPG FP: DE10 73FD 17EB 5544 A491 B385 1EDA 35DC FF39 5BD9
czezz
2014-11-27 20:11:48 UTC
Permalink
Hi, thanks for quick reply
I was thinking this same but it seems to be OK with permissions.
Here is WWW dir:
***@proxy:/var/lib/monitorix/www# pwd
/var/lib/monitorix/www
***@proxy:/var/lib/monitorix/www# ls -al
total 44
drwxr-xr-x 6 root root   4096 2014-11-27 00:07 ./
drwxr-xr-x 3 root root   4096 2014-11-27 00:07 ../
drwxr-xr-x 2 root root   4096 2014-11-26 23:27 cgi/
drwxrwx--- 2 root nobody 4096 2014-11-27 21:09 imgs/
-rw-r--r-- 1 root root   5490 2014-11-27 21:06 index.html
-rw-r--r-- 1 root root   1870 2014-11-26 22:54 logo_bot.png
-rw-r--r-- 1 root root   4021 2014-11-26 22:54 logo_top.png
-rw-r--r-- 1 root root   2251 2014-11-26 22:54 monitorixico.png
drwxr-xr-x 2 root root   4096 2014-11-26 22:54 reports/
drwxrwx--- 2 root root   4096 2014-11-26 22:54 usage/
BR,
czezz
Dnia 27 listopada 2014 21:06 Bertrand Caplet &lt;***@chunkz.net&gt; napisał(a):
&gt; I have installed Monitorix 3.6 on my old Slackware 12 box.
&gt; I have compiled it using SlackBuilds.
&gt; For some reason when I start monitorix and access over web browser, no
&gt; pictures are displayed and I get following error in /var/log/monitorix
&gt; - libpng error: Write Error.
&gt; libpng is installed with following version: libpng-1.2.50-i486-1_slack12.0
&gt;
&gt; Can anyone please help me out here what is wrong
Hey Czezz,
It seems you have permissions errors.
where is you root directory of monitorix ?
Who own it ?
see in
&lt;httpd_builtin&gt;
user = nobody
group = nobody
&lt;/httpd_builtin&gt;
That's the default.
Regards,
czezz
2014-11-27 20:14:26 UTC
Permalink
Additionally listing from /etc/monitorix/monitorix.conf:
base_dir = /var/lib/monitorix/www/
base_lib = /var/lib/monitorix/
base_url = /
base_cgi = /cgi
&lt;httpd_builtin&gt;
        enabled = y
        host =
        port = 18080
        user = nobody
        group = nobody
        log_file = /var/log/monitorix-httpd
        hosts_deny =
        hosts_allow =
        &lt;auth&gt;
                enabled = n
                msg = Monitorix: Restricted access
                htpasswd = /var/lib/monitorix/htpasswd
        &lt;/auth&gt;
&lt;/httpd_builtin&gt;
Dnia 27 listopada 2014 21:11 czezz &lt;***@o2.pl&gt; napisał(a):
Hi, thanks for quick reply
I was thinking this same but it seems to be OK with permissions.
Here is WWW dir:
***@proxy:/var/lib/monitorix/www# pwd
/var/lib/monitorix/www
***@proxy:/var/lib/monitorix/www# ls -al
total 44
drwxr-xr-x 6 root root   4096 2014-11-27 00:07 ./
drwxr-xr-x 3 root root   4096 2014-11-27 00:07 ../
drwxr-xr-x 2 root root   4096 2014-11-26 23:27 cgi/
drwxrwx--- 2 root nobody 4096 2014-11-27 21:09 imgs/
-rw-r--r-- 1 root root   5490 2014-11-27 21:06 index.html
-rw-r--r-- 1 root root   1870 2014-11-26 22:54 logo_bot.png
-rw-r--r-- 1 root root   4021 2014-11-26 22:54 logo_top.png
-rw-r--r-- 1 root root   2251 2014-11-26 22:54 monitorixico.png
drwxr-xr-x 2 root root   4096 2014-11-26 22:54 reports/
drwxrwx--- 2 root root   4096 2014-11-26 22:54 usage/
BR,
czezz
Dnia 27 listopada 2014 21:06 Bertrand Caplet &lt;***@chunkz.net&gt; napisał(a):
&gt; I have installed Monitorix 3.6 on my old Slackware 12 box.
&gt; I have compiled it using SlackBuilds.
&gt; For some reason when I start monitorix and access over web browser, no
&gt; pictures are displayed and I get following error in /var/log/monitorix
&gt; - libpng error: Write Error.
&gt; libpng is installed with following version: libpng-1.2.50-i486-1_slack12.0
&gt;
&gt; Can anyone please help me out here what is wrong
Hey Czezz,
It seems you have permissions errors.
where is you root directory of monitorix ?
Who own it ?
see in
&lt;httpd_builtin&gt;
user = nobody
group = nobody
&lt;/httpd_builtin&gt;
That's the default.
Regards,
Bertrand Caplet
2014-11-27 20:22:46 UTC
Permalink
Post by czezz
base_dir = /var/lib/monitorix/www/
base_lib = /var/lib/monitorix/
base_url = /
base_cgi = /cgi
<httpd_builtin>
enabled = y
host =
port = 18080
user = nobody
group = nobody
log_file = /var/log/monitorix-httpd
hosts_deny =
hosts_allow =
<auth>
enabled = n
msg = Monitorix: Restricted access
htpasswd = /var/lib/monitorix/htpasswd
</auth>
</httpd_builtin>
Well try anyway with user = root and group = root
just to be sure. If it's the same, double-check the dependencies are
installed.

Regards,
--
CHUNKZ.NET - casual fiddler and computer technician
Bertrand Caplet, Flers (FR)
Feel free to send encrypted/signed messages
Key ID: FF395BD9
GPG FP: DE10 73FD 17EB 5544 A491 B385 1EDA 35DC FF39 5BD9
czezz
2014-11-27 20:36:18 UTC
Permalink
I changed owner to root and added permissions to 777 and now it works.
I need to look closer how fix it.
Thank you for your help.
BR,
czezz
 
Dnia 27 listopada 2014 21:22 Bertrand Caplet &lt;***@chunkz.net&gt; napisał(a):
&gt; Additionally listing from /etc/monitorix/monitorix.conf:
&gt;
&gt; base_dir = /var/lib/monitorix/www/
&gt; base_lib = /var/lib/monitorix/
&gt; base_url = /
&gt; base_cgi = /cgi
&gt;
&gt; &lt;httpd_builtin&gt;
&gt; enabled = y
&gt; host =
&gt; port = 18080
&gt; user = nobody
&gt; group = nobody
&gt; log_file = /var/log/monitorix-httpd
&gt; hosts_deny =
&gt; hosts_allow =
&gt; &lt;auth&gt;
&gt; enabled = n
&gt; msg = Monitorix: Restricted access
&gt; htpasswd = /var/lib/monitorix/htpasswd
&gt; &lt;/auth&gt;
&gt; &lt;/httpd_builtin&gt;
Well try anyway with user = root and group = root
just to be sure. If it's the same, double-check the dependencies are
installed.
Regards,
Jordi Sanfeliu
2014-11-27 20:51:59 UTC
Permalink
Czezz,

Perhaps you ran Monitorix in the first instance with a different user
name, and then you changed it to 'nobody:nobody'. But some graphs were
already created into the 'imgs/' directory with the old permissions set.
Now, when running under 'nobody:nobody' it attempts to overwrite such
files but fails because these files are owned by a different user.

So, please, try removing all the files inside the 'imgs/' directory,
reset the owner and group of the built-in HTTP server to 'nobody:nobody'
and check again.

Regards.

---
Jordi Sanfeliu
FIBRANET Network Services Provider
http://www.fibranet.cat
Post by czezz
I changed owner to root and added permissions to 777 and now it works.
I need to look closer how fix it.
Thank you for your help.
BR,
czezz
Dnia 27 listopada 2014 21:22 Bertrand Caplet
Post by Bertrand Caplet
Post by czezz
base_dir = /var/lib/monitorix/www/
base_lib = /var/lib/monitorix/
base_url = /
base_cgi = /cgi
<httpd_builtin>
enabled = y
host =
port = 18080
user = nobody
group = nobody
log_file = /var/log/monitorix-httpd
hosts_deny =
hosts_allow =
<auth>
enabled = n
msg = Monitorix: Restricted access
htpasswd = /var/lib/monitorix/htpasswd
</auth>
</httpd_builtin>
Well try anyway with user = root and group = root
just to be sure. If it's the same, double-check the dependencies are
installed.
Regards,
Bertrand Caplet
2014-11-27 20:55:11 UTC
Permalink
Post by czezz
I changed owner to root and added permissions to 777 and now it works.
I need to look closer how fix it.
Thank you for your help.
BR,
czezz
Well now do chmod -R a-r-w-x-s-t,a+r+X,u+w /var/lib/monitorix/www
then chown -R nobody:nobody /var/lib/monitorix/www

and this would get fixed ;-)

Regards,
--
CHUNKZ.NET - casual fiddler and computer technician
Bertrand Caplet, Flers (FR)
Feel free to send encrypted/signed messages
Key ID: FF395BD9
GPG FP: DE10 73FD 17EB 5544 A491 B385 1EDA 35DC FF39 5BD9
Bertrand Caplet
2014-12-02 17:46:55 UTC
Permalink
1.
# cpan
(optional) cpan> install Bundle::CPAN
cpan> install HTTP::Server::Simple::CGI
cpan> install Config::General
# installpkg libart_lgpl-2.3.19-i486-1.tgz
# installpkg rrdtool-1.2.19-i486-1_SBo.tgz
# installpkg monitorix-3.6.0-i486-1_SBo.tgz
Note: you may require to install more libs in point 2a. In this case
refer to /var/log/monitorix log file.
BR,
czezz
That's nice from you. If you guys read me could you please add this to
monitorix.org ?

I'll try monitorix on openBSD I will post a Howto too.

Regards
--
CHUNKZ.NET - script kiddie and computer technician
Bertrand Caplet, Flers (FR)
Feel free to send encrypted/signed messages
Key ID: FF395BD9
GPG FP: DE10 73FD 17EB 5544 A491 B385 1EDA 35DC FF39 5BD9
Jordi Sanfeliu
2014-12-04 07:29:27 UTC
Permalink
Bertrand,

I'll do.
Let me know when you have finished your OpenBSD Howto.

Regards.
Post by Bertrand Caplet
1.
# cpan
(optional) cpan> install Bundle::CPAN
cpan> install HTTP::Server::Simple::CGI
cpan> install Config::General
# installpkg libart_lgpl-2.3.19-i486-1.tgz
# installpkg rrdtool-1.2.19-i486-1_SBo.tgz
# installpkg monitorix-3.6.0-i486-1_SBo.tgz
Note: you may require to install more libs in point 2a. In this case
refer to /var/log/monitorix log file.
BR,
czezz
That's nice from you. If you guys read me could you please add this to
monitorix.org ?
I'll try monitorix on openBSD I will post a Howto too.
Regards
--
Jordi Sanfeliu
FIBRANET Network Services Provider
http://www.fibranet.cat
Jordi Sanfeliu
2014-12-04 07:28:01 UTC
Permalink
Czezz,

Thanks for sharing this information.
I'll put as is in the Monitorix web site.

Regards.
Hi,
decided to erase it all and start from scratch.
Now it works all OK.
By the way - I want to post here a short guide how to install monitorix
on Slackware 12. (It should work also for any newer Slackware release).
1.
# cpan
(optional) cpan> install Bundle::CPAN
cpan> install HTTP::Server::Simple::CGI
cpan> install Config::General
# installpkg libart_lgpl-2.3.19-i486-1.tgz
# installpkg rrdtool-1.2.19-i486-1_SBo.tgz
# installpkg monitorix-3.6.0-i486-1_SBo.tgz
Note: you may require to install more libs in point 2a. In this case
refer to /var/log/monitorix log file.
BR,
czezz
--
Jordi Sanfeliu
FIBRANET Network Services Provider
http://www.fibranet.cat
Continue reading on narkive:
Search results for '[Monitorix-general] libpng error: Write Error' (Questions and Answers)
3
replies
How safe is it to...?
started 2007-07-29 10:05:54 UTC
programming & design
Loading...