Koozali.org: home of the SME Server

Phreebooks install (accounting/ERP package)

Offline Stefano

  • *
  • 10,838
  • +2/-0
Re: Phreebooks install (accounting/ERP package)
« Reply #30 on: December 18, 2012, 12:50:07 PM »
Charles, check your logs..

you can also display php errors (if any)

please read here: http://wiki.contribs.org/PHP#Display_Error_Messages

Offline Charles2008

  • *
  • 174
  • +0/-0
Re: Phreebooks install (accounting/ERP package)
« Reply #31 on: December 18, 2012, 05:01:04 PM »
Hi Stefano

var/log/httpd/error_log :
For today:

Code: [Select]
[Tue Dec 18 09:00:37 2012] [notice] Graceful restart requested, doing restart
[Tue Dec 18 09:00:37 2012] [notice] Digest: generating secret for digest authentication ...
[Tue Dec 18 09:00:37 2012] [notice] Digest: done
[Tue Dec 18 09:00:37 2012] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
[Tue Dec 18 09:00:37 2012] [warn] RSA server certificate CommonName (CN) `server.home.com' does NOT match server name!?
[Tue Dec 18 09:00:37 2012] [notice] Apache configured -- resuming normal operations
[Tue Dec 18 09:03:11 2012] [notice] Graceful restart requested, doing restart
[Tue Dec 18 09:03:11 2012] [notice] Digest: generating secret for digest authentication ...
[Tue Dec 18 09:03:11 2012] [notice] Digest: done
[Tue Dec 18 09:03:11 2012] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
[Tue Dec 18 09:03:11 2012] [warn] RSA server certificate CommonName (CN) `server.home.com' does NOT match server name!?
[Tue Dec 18 09:03:11 2012] [notice] Apache configured -- resuming normal operations
[Tue Dec 18 09:06:31 2012] [notice] Graceful restart requested, doing restart
[Tue Dec 18 09:06:31 2012] [notice] Digest: generating secret for digest authentication ...
[Tue Dec 18 09:06:31 2012] [notice] Digest: done
[Tue Dec 18 09:06:32 2012] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
[Tue Dec 18 09:06:32 2012] [warn] RSA server certificate CommonName (CN) `server.home.com' does NOT match server name!?
[Tue Dec 18 09:06:32 2012] [notice] Apache configured -- resuming normal operations
[Tue Dec 18 09:33:18 2012] [notice] Graceful restart requested, doing restart
[Tue Dec 18 09:33:18 2012] [notice] Digest: generating secret for digest authentication ...
[Tue Dec 18 09:33:18 2012] [notice] Digest: done
[Tue Dec 18 09:33:18 2012] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
[Tue Dec 18 09:33:18 2012] [warn] RSA server certificate CommonName (CN) `server.home.com' does NOT match server name!?
[Tue Dec 18 09:33:18 2012] [notice] Apache configured -- resuming normal operations
[Tue Dec 18 09:34:22 2012] [notice] Graceful restart requested, doing restart
[Tue Dec 18 09:34:22 2012] [notice] Digest: generating secret for digest authentication ...
[Tue Dec 18 09:34:22 2012] [notice] Digest: done
[Tue Dec 18 09:34:22 2012] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
[Tue Dec 18 09:34:22 2012] [warn] RSA server certificate CommonName (CN) `server.home.com' does NOT match server name!?
[Tue Dec 18 09:34:22 2012] [notice] Apache configured -- resuming normal operations
[Tue Dec 18 09:39:16 2012] [notice] Graceful restart requested, doing restart
[Tue Dec 18 09:39:16 2012] [notice] Digest: generating secret for digest authentication ...
[Tue Dec 18 09:39:16 2012] [notice] Digest: done
[Tue Dec 18 09:39:16 2012] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
[Tue Dec 18 09:39:16 2012] [warn] RSA server certificate CommonName (CN) `server.home.com' does NOT match server name!?
[Tue Dec 18 09:39:16 2012] [notice] Apache configured -- resuming normal operations
[Tue Dec 18 10:10:36 2012] [notice] Graceful restart requested, doing restart
[Tue Dec 18 10:10:36 2012] [notice] Digest: generating secret for digest authentication ...
[Tue Dec 18 10:10:36 2012] [notice] Digest: done
[Tue Dec 18 10:10:36 2012] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
[Tue Dec 18 10:10:36 2012] [warn] RSA server certificate CommonName (CN) `server.home.com' does NOT match server name!?
[Tue Dec 18 10:10:36 2012] [notice] Apache configured -- resuming normal operations


/var/log/messages:

Code: [Select]
Dec 18 11:03:49 server esmith::event[24489]: WARNING: Template processing succeeded for //etc/proftpd.conf: 1 fragment generated warnings
Dec 18 11:03:49 server esmith::event[24489]:  at /etc/e-smith/events/actions/generic_template_expand line 56
Dec 18 11:03:49 server esmith::event[24489]: expanding /etc/securetty
Dec 18 11:03:49 server esmith::event[24489]: expanding /etc/httpd/conf/httpd.conf
Dec 18 11:03:50 server esmith::event[24489]: WARNING in /etc/e-smith/templates//etc/httpd/conf/httpd.conf/90e-smithAccess40ibays: Use of uninitialized value$
Dec 18 11:03:50 server esmith::event[24489]: WARNING in /etc/e-smith/templates//etc/httpd/conf/httpd.conf/90e-smithAccess40ibays: Use of uninitialized value$
Dec 18 11:03:50 server esmith::event[24489]: WARNING in /etc/e-smith/templates//etc/httpd/conf/httpd.conf/90e-smithAccess40ibays: Use of uninitialized value$
Dec 18 11:03:50 server esmith::event[24489]: WARNING: Template processing succeeded for //etc/httpd/conf/httpd.conf: 3 fragments generated warnings
Dec 18 11:03:50 server esmith::event[24489]:  at /etc/e-smith/events/actions/generic_template_expand line 56
Dec 18 11:03:50 server esmith::event[24489]: expanding /etc/samba/smbusers
Dec 18 11:03:50 server esmith::event[24489]: expanding /etc/samba/smb.conf
Dec 18 11:03:50 server esmith::event[24489]: generic_template_expand=action|Event|ibay-modify|Action|generic_template_expand|Start|1355828629 472159|End|135$
Dec 18 11:03:50 server esmith::event[24489]: Running event handler: /etc/e-smith/events/ibay-modify/S15ibay-modify
Dec 18 11:03:50 server esmith::event[24489]: User accounts successfully modified!
Dec 18 11:03:51 server esmith::event[24489]: S15ibay-modify=action|Event|ibay-modify|Action|S15ibay-modify|Start|1355828630 676902|End|1355828631 133203|Ela$
Dec 18 11:03:51 server esmith::event[24489]: Running event handler: /etc/e-smith/events/actions/adjust-services
Dec 18 11:03:51 server esmith::event[24489]: adjusting supervised httpd-e-smith (sigusr1)
Dec 18 11:03:51 server esmith::event[24489]: adjusting supervised httpd-e-smith (up)
Dec 18 11:03:51 server esmith::event[24489]: adjusting supervised smbd (sighup)
Dec 18 11:03:51 server esmith::event[24489]: adjusting supervised smbd (up)
Dec 18 11:03:51 server esmith::event[24489]: adjust-services=action|Event|ibay-modify|Action|adjust-services|Start|1355828631 133670|End|1355828631 260372|E$
Dec 18 11:03:51 server esmith::event[24489]: Running event handler: /etc/e-smith/events/ibay-modify/S95ldap-update-simple
Dec 18 11:03:51 server esmith::event[24489]: S95ldap-update-simple=action|Event|ibay-modify|Action|S95ldap-update-simple|Start|1355828631 260828|End|1355828$
Dec 18 11:16:30 server /sbin/e-smith/db[25251]: /home/e-smith/db/accounts: OLD accounts=ibay|AllowOverride|All|CgiBin|enabled|FollowSymLinks|enabled|Gid|500$
Dec 18 11:16:30 server /sbin/e-smith/db[25251]: /home/e-smith/db/accounts: NEW accounts=ibay|AllowOverride|All|CgiBin|enabled|FollowSymLinks|enabled|Gid|500$
Dec 18 11:16:49 server esmith::event[25271]: Processing event: ibay-modify accounts
Dec 18 11:16:49 server esmith::event[25271]: Running event handler: /etc/e-smith/events/actions/generic_template_expand
Dec 18 11:16:50 server esmith::event[25271]: expanding /etc/services
Dec 18 11:16:50 server esmith::event[25271]: expanding /etc/hosts.allow
Dec 18 11:16:50 server esmith::event[25271]: expanding /etc/shells
Dec 18 11:16:50 server esmith::event[25271]: expanding /etc/hosts.deny
Dec 18 11:16:50 server esmith::event[25271]: expanding /etc/proftpd.conf
Dec 18 11:16:50 server esmith::event[25271]: expanding /etc/securetty
Dec 18 11:16:50 server esmith::event[25271]: expanding /etc/httpd/conf/httpd.conf
Dec 18 11:16:50 server esmith::event[25271]: expanding /etc/samba/smbusers
Dec 18 11:16:50 server esmith::event[25271]: expanding /etc/samba/smb.conf
Dec 18 11:16:51 server esmith::event[25271]: generic_template_expand=action|Event|ibay-modify|Action|generic_template_expand|Start|1355829409 989818|End|135$
Dec 18 11:16:51 server esmith::event[25271]: Running event handler: /etc/e-smith/events/ibay-modify/S15ibay-modify
Dec 18 11:16:51 server esmith::event[25271]: User accounts successfully modified!
Dec 18 11:16:51 server esmith::event[25271]: S15ibay-modify=action|Event|ibay-modify|Action|S15ibay-modify|Start|1355829411 189103|End|1355829411 952453|Ela$
Dec 18 11:16:51 server esmith::event[25271]: Running event handler: /etc/e-smith/events/actions/adjust-services
Dec 18 11:16:52 server esmith::event[25271]: adjusting supervised httpd-e-smith (sigusr1)
Dec 18 11:16:52 server esmith::event[25271]: adjusting supervised httpd-e-smith (up)
Dec 18 11:16:52 server esmith::event[25271]: adjusting supervised smbd (sighup)
Dec 18 11:16:52 server esmith::event[25271]: adjusting supervised smbd (up)
Dec 18 11:16:52 server esmith::event[25271]: adjust-services=action|Event|ibay-modify|Action|adjust-services|Start|1355829411 952913|End|1355829412 79217|El$
Dec 18 11:16:52 server esmith::event[25271]: Running event handler: /etc/e-smith/events/ibay-modify/S95ldap-update-simple
Dec 18 11:16:52 server esmith::event[25271]: S95ldap-update-simple=action|Event|ibay-modify|Action|S95ldap-update-simple|Start|1355829412 79677|End|13558294$
Dec 18 11:18:03 server httpd: PHP Warning:  Unknown: open_basedir restriction in effect. File(/home/e-smith/files/ibays/accounts/html/index.php) is not with$
Dec 18 11:18:03 server httpd: PHP Warning:  Unknown: failed to open stream: Operation not permitted in Unknown on line 0

Is that enough information?
Charles


« Last Edit: December 18, 2012, 05:03:34 PM by Charles2008 »

guest22

Re: Phreebooks install (accounting/ERP package)
« Reply #32 on: December 18, 2012, 05:10:35 PM »
Charles2008,

messages log second last row says:

Dec 18 11:18:03 server httpd: PHP Warning:  Unknown: open_basedir restriction in effect. File(/home/e-smith/files/ibays/accounts/html/index.php) is not with$

That is why you get a blank screen

What is the result of:

db accounts show accounts

please?



Offline Charles2008

  • *
  • 174
  • +0/-0
Re: Phreebooks install (accounting/ERP package)
« Reply #33 on: December 18, 2012, 05:15:10 PM »
RequestedDeletion

# db accounts show accounts
accounts=ibay
    AllowOverride=All
    CgiBin=enabled
    FollowSymLinks=enabled
    Gid=5002
    Group=www
    Name=accounts
    PHPBaseDir=/home/e-smith/files/ibays/accounts/html/tmp
    PasswordSet=yes
    PublicAccess=global
    Uid=5002
    UserAccess=wr-group-rd-everyone

Charles

guest22

Re: Phreebooks install (accounting/ERP package)
« Reply #34 on: December 18, 2012, 05:22:28 PM »
Thinking out loud, could it be that a closing '/' is required?

PHPBaseDir=/home/e-smith/files/ibays/accounts/html/tmp

can you try to change it by:

db accounts setprop accounts PHPBaseDir /home/e-smith/files/ibays/accounts/html/tmp/

and then modify ibay command?

Offline Stefano

  • *
  • 10,838
  • +2/-0
Re: Phreebooks install (accounting/ERP package)
« Reply #35 on: December 18, 2012, 05:26:03 PM »
there's an error

Code: [Select]
db accounts setprop accounts PHPBaseDir /home/e-smith/files/ibays/accounts/html/


Offline Stefano

  • *
  • 10,838
  • +2/-0
Re: Phreebooks install (accounting/ERP package)
« Reply #36 on: December 18, 2012, 05:27:07 PM »
if you want to have a "local" tmp dir, you should tell it to php or to your application

guest22

Re: Phreebooks install (accounting/ERP package)
« Reply #37 on: December 18, 2012, 05:30:10 PM »
@Stefano

ahhhhhh by *ONLY* indicating the /tmp/ directory in as OpenBaseDir, we 'jail' the PHP application execution *ONLY* to the /tmp directory and not allowing access to the htl directory itself....

db accounts setprop accounts PHPBaseDir /home/e-smith/files/ibays/accounts/html/

then we DO need a custom template fragment to tell the PHP app where it's tmp directory is...



guest22

Re: Phreebooks install (accounting/ERP package)
« Reply #38 on: December 18, 2012, 05:34:00 PM »
I guess Charles2008 is completely confused by now, sorry for that :-)

Offline Charles2008

  • *
  • 174
  • +0/-0
Re: Phreebooks install (accounting/ERP package)
« Reply #39 on: December 18, 2012, 05:36:28 PM »
RequestedDeletion
tried it
db accounts show accounts

Code: [Select]
PHPBaseDir=/home/e-smith/files/ibays/accounts/html/tmp/
still 'white screen' for 'accounts' and normal login for 'server-manager'


Stefano
Ahhh Ha! That has the login screen back - thank you.


RequestedDeletion
Now I still can't modify or add information.
If you still have you i-bay Phreedom install, are you able to add / modify information on yours?
e.g can you enter Phreebooks and, just below the blue control bar there is
"Add Dashboard items to menu"
If you click this and then select 2 or 3 of the offered Dashboard reports - can you then save them by clicking on the 'diskette' image in the top LHS corner? Do they display on the dashboard after having clicked on 'home' top LHS corner?

Charles


guest22

Re: Phreebooks install (accounting/ERP package)
« Reply #40 on: December 18, 2012, 05:42:21 PM »
@Charles2008

my test install in iBay 'phreebooks' is fully functional, including client attachments, reports etc. But the again, I have the custom template fragment. To edit you can use the nano [filename] command.

Code: [Select]
- Make a custom-template copy of 95AddType00PHP2ibays:

mkdir -p /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf
cd /etc/e-smith/templates-custom/etc/httpd/conf/httpd.conf
cp /etc/e-smith/templates/etc/httpd/conf/httpd.conf/95AddType00PHP2ibays .
(don't miss the "." at the end of the last line)

Edit the custom-template version of 95AddType00PHP2ibays and add the three lines preceded by "+" below:


                my $basedir = $ibay->prop('PHPBaseDir')
                    || ("/home/e-smith/files/ibays/" . $ibay->key . "/");
                $OUT .= "    php_admin_value open_basedir $basedir\n";
+                my $tmpdir = $ibay->prop('PHPTmpDir')
+                    || ("/home/e-smith/files/ibays/" . $ibay->key . "/tmp");
+                $OUT .= "    php_admin_value upload_tmp_dir $tmpdir\n";
                $OUT .= "</Directory>\n";

expand-template /etc/httpd/conf/httpd.conf
signal-event remoteaccess-update


Keep in mind that the 3 new lines will add the /html/tmp/ dirctory and the upload_tmp_dir indicator to ALL iBays, existing and newly created.

Offline janet

  • ****
  • 4,812
  • +0/-0
Re: Phreebooks install (accounting/ERP package)
« Reply #41 on: December 18, 2012, 05:55:19 PM »
Charles2008 & all

I think this should achieve both requirements, ie access to .../html and ..../html/tmp
db accounts setprop accounts PHPBaseDir /home/e-smith/files/ibays/accounts/html:/home/e-smith/files/ibays/accounts/html/tmp
(the above all on one line)
signal-event ibay-modify accounts

and further

you should check the configuration file for the app, usually something like config.php or phreeconfig.php or similar and see what it specifies for the temp location  (if anything).
This is usually found in ..../html or ..../html/admin or similar depending on the app folder structure
You csn make changes to this config file, and these will be retained. Make a note of any settings before you change them, and ideally make a safe copy of the config file before you make changes, in case you need to revert to the old file.

I see you access Handisoft, are you or your client a Public Accountant ?
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline Stefano

  • *
  • 10,838
  • +2/-0
Re: Phreebooks install (accounting/ERP package)
« Reply #42 on: December 18, 2012, 06:04:19 PM »
I think this should achieve both requirements, ie access to .../html and ..../html/tmp
db accounts setprop accounts PHPBaseDir /home/e-smith/files/ibays/accounts/html:/home/e-smith/files/ibays/accounts/html/tmp

I disagree :-)
if tmp is a html's subdirectory, there's no reason to add its path

Offline Charles2008

  • *
  • 174
  • +0/-0
Re: Phreebooks install (accounting/ERP package)
« Reply #43 on: December 18, 2012, 06:16:21 PM »
...  I guess I should have waited.

I carried out the instructions and still nothing has changed. I am wondering whether it has something to do with one line of my
95AddType00PHP2ibays
wrapping around on itself. I copied and pasted it in, however it is insisting on wrapping around - as shown below. Does this matter, or is it nothing (I think I have seen elsewhere on the forum this sort of innocent looking thing making 'all the difference').


 
Code: [Select]
               # Set the sandbox within which PHP is confined to play
                my $basedir = $ibay->prop('PHPBaseDir')
                    || ("/home/e-smith/files/ibays/" . $ibay->key . "/");
                $OUT .= "    php_admin_value open_basedir $basedir\n";
                 my $tmpdir = $ibay->prop('PHPTmpDir')
                     || ("/home/e-smith/files/ibays/" . $ibay->key .
"/tmp");
                   $OUT .= "    php_admin_value upload_tmp_dir $tmpdir\n";


Offline Stefano

  • *
  • 10,838
  • +2/-0
Re: Phreebooks install (accounting/ERP package)
« Reply #44 on: December 18, 2012, 06:21:38 PM »
Charles2008:

edit your file with
Code: [Select]
nano -w filename

and check for unwanted wordwrapping