Koozali.org: home of the SME Server

Problems with PHPSysInfo

Offline Rien

  • *
  • 216
  • +0/-0
    • http://www.taurix.nl
Problems with PHPSysInfo
« on: January 20, 2005, 09:00:59 PM »
Hi all,

I have a strange problem. I use the phpsysinfo-2.3.tar.gz. Everything works fine but the Mounted Filesystems section is empty.

What could be wrong?
Rien
(The Netherlands)......

the_mad_prof

Problems with PHPSysInfo
« Reply #1 on: January 21, 2005, 02:45:36 PM »
Hiya,

have you given the ibay access to the /proc directory?

If you haven't done so already you need to run

/sbin/e-smith/db accounts setprop <ibay_name> PHPBaseDir /home/e-smith/files/ibays/<ibay_name>/:/proc:/bin

then

/sbin/e-smith/signal-event ibay-modify <ibay-name>

Hope this helps!

Offline Rien

  • *
  • 216
  • +0/-0
    • http://www.taurix.nl
Problems with PHPSysInfo
« Reply #2 on: January 21, 2005, 06:38:30 PM »
Thanks, it works now.

I did:

Code: [Select]
[root@e-smith ]# /sbin/e-smith/db accounts setprop <ibay_name> PHPBaseDir /home/e-smith/files/ibays/<ibay_name>/:/proc

[root@e-smith ]# /sbin/e-smith/signal-event ibay-modify <ibay_name>


This is what te How to "Install PhpSysInfo in an IBay" contributed by Martin Elhøj says. (maybe based on another version?)

Do you know how I can get the distro name right? (now I get "N.A.")
Rien
(The Netherlands)......

ejfowler

display smeserver distro name in phpsysinfo
« Reply #3 on: February 01, 2005, 04:47:34 AM »
I fixed the distro name on phpsysinfo ion my smeserver, here's how:

1) Open the class.Linux.inc.php file with your favorite text editor. Mine is located at:

/opt/administration/phpsysinfo/includes/os

I use the phpsysinfo-public contrib by nightspirit. Yours may be elsewhere.

2) Find the function distro section, it's near the end of the file. Add the following lines after the redhat-release stanza:

   } elseif ($fd = fopen('/etc/e-smith-release', 'r')) {
      $buf = fgets($fd, 1024);
      fclose($fd);
      $result = trim($buf);

3) Find the function distroicon section, it's at the end of the file. Add the following lines after the redhat-release stanza:

   } elseif (file_exists('/etc/e-smith-release')) {
      $result = 'smeserver.png';

4) Use your favorite icon editor to rip an image from the contribs.org website graphics. Save it as smeserver.png (or whatever graphics format you prefer, edit preceeding stanza accordingly) in the /opt/administration/phpsysinfo/images directory.

5) Enjoy your new custom icon and distro name display in phpsysinfo on smeserver!