Koozali.org: home of the SME Server

Allow Wirte Access to I-Bay Account

Ian

Re: Allow Wirte Access to I-Bay Account
« Reply #15 on: September 15, 2003, 02:56:43 AM »
One other problem since i put the  # infront of the sandbox things i get this when i try to access server manager


Proxy Error
The proxy server received an invalid response from an upstream server.
The proxy server could not handle the request GET /server-manager/.

Reason: Could not connect to remote machine: Connection refused

Ian

Re: Allow Wirte Access to I-Bay Account
« Reply #16 on: September 15, 2003, 04:23:15 AM »
Ian wrote:
>
> One other problem since i put the  # infront of the sandbox
> things i get this when i try to access server manager
>
>
> Proxy Error
> The proxy server received an invalid response from an
> upstream server.
> The proxy server could not handle the request GET
> /server-manager/.
>
> Reason: Could not connect to remote machine: Connection refused

Disregard i needed to reboot

Bill Pflaumer

Re: Allow Wirte Access to I-Bay Account
« Reply #17 on: September 15, 2003, 08:46:18 AM »
Ian,
I can help you get through the php upload limitations, but you need to do something for me. First, come down off your speedball and stop leaving 4 billon posts on this forum. Second, is Research,Research and Research. I have no problem uploading 50MB files using this script but the answer did not walk through the door .

Talk to you tomorrow,
Bill

Ian

Re: Allow Wirte Access to I-Bay Account
« Reply #18 on: September 15, 2003, 04:42:36 PM »
Bill,  Thanks for the advise on the speedball problem of mine.  Secondly I have researched both here and on the makers website and can not find the answer to my problem (maybe you know someplace I dont).  Please look at my other post on the board I have posted my INI file and my PHP file for trouble shooting.  Thanks in advance.

Amazing Iceman

Re: Allow Wirte Access to I-Bay Account
« Reply #19 on: September 15, 2003, 11:52:46 PM »
Thanks again, Bill...

Just one question: What are the side-effects for disabling the PHP Sandbox?

I imagine that there must be a reason why it was implemented, and if we are disabling it, something else may stop working.

The script seems to be very well written. Now we just need someone capable of writing a plug-in for the Server Manager for easier management.

Thanks to everyone who posted their replies to my messages.

-- The Amazing Iceman

Amazing Iceman

Re: Allow Write Access to I-Bay Account - PROBLEM SOLVED
« Reply #20 on: September 16, 2003, 12:13:02 AM »
Hello Everyone,

Thanks to all the infomation you provided in your posts, I was able to modify the script to solve the problem.

Here's what you need to do:

1) Open the script in vi
2) Go to line 1148 and only change @copy to @move_uploaded_file.
3) Save the script, and it now works...

I will keep testing the script, and if I run into errors I will post them here.

Thanks again,

-- The Amazing Iceman

Mark Thomas

Re: Allow Write Access to I-Bay Account - PROBLEM SOLVED
« Reply #21 on: September 16, 2003, 02:41:00 AM »
iceman, are you referring to the 'webFileBrowser.php file ??

if so, mine is as follows;
1146 if (@copy($HTTP_POST_FILES["file"]["tmp_name"], $fp)) {
1147 @unlink($HTTP_POST_FILES["file"]["tmp_name"]);
1148 @chmod($fp, $filemode);

Amazing Iceman

Re: Allow Write Access to I-Bay Account - PROBLEM SOLVED
« Reply #22 on: September 16, 2003, 04:07:21 AM »
Yes, I'm referring to the 'webFileBrowser.php file. I renamed mine to index.php and renamed the original index.html file that appears when you create an ibay.

I'm trying to fix the MaxUploadSize values, it seems that there's more than one place that needs to be changed.

Amazing Iceman

Re: Allow Write Access to I-Bay Account - Download issue on
« Reply #23 on: September 16, 2003, 04:46:06 AM »
Guess what.... On SME 6.0 I cannot download files. I can Upload, but not download...

Very strange... PLease let me know if someone else is having problems with 6.0.

Thanks

Mark Thomas

Re: Allow Write Access to I-Bay Account - Download issue on
« Reply #24 on: September 16, 2003, 05:46:25 AM »
I'm using 6beta3 and I can D/L and U/L, but  only small files, less than 1MB.

I created a custom template for the php.ini file and changed the '60FileUploads' to this.
'UploadMaxFilesize') || "10M";

I also changed the webFileBrowser.php file to this.
$uploadmaxsize = 10485760

but still no luck *shrug*

Bill Pflaumer

Re: Allow Write Access to I-Bay Account - Download issue on
« Reply #25 on: September 16, 2003, 04:21:42 PM »
The following quote is from a Charlie Brady Howto to increase the size of webmail attachments and other PHP apps. It came with an RPM to install, but fails to install on SME6B3 because of version conflicts. I entered the following without the RPM install and worked for me.  



Add these settings into the configuration database to increase the maximum attachment size to 25MB:

/sbin/e-smith/config setprop php MaxExecutionTime 1800
/sbin/e-smith/config setprop php MemoryLimit 100M
/sbin/e-smith/config setprop php PostMaxSize 25M
/sbin/e-smith/config setprop php UploadMaxFilesize 25M

Expand the template:

/etc/e-smith/events/actions/conf-php

Then restart httpd:

/etc/rc.d/init.d/httpd-e-smith graceful

Ian

Re: Allow Write Access to I-Bay Account - Download issue on
« Reply #26 on: September 17, 2003, 07:22:45 AM »
Expand the template:  (what need to be done once you expanded it)

/etc/e-smith/events/actions/conf-php

Then restart httpd:

/etc/rc.d/init.d/httpd-e-smith graceful (what does graceful mean here)

I am not new to sme but I am quite confused as to what is ment by these four lines coudl someone please explain it to me in laymens terms and exactly what i need to do

Amazing Iceman

Re: Allow Write Access to I-Bay Account - Download issue on
« Reply #27 on: September 17, 2003, 06:17:33 PM »
This is what I did:

1) Copy the following templates from the /etc/e-smith/templates/etc/php.ini/ directory to the /etc/e-smithtemplates-custom/etc/php.ini/ directory:

20ResourceLimits
40DataHandling
60FileUploads

2) Open each template and edit the following values as you find them:
max_execution_time 1800
memory__limit 100M
post_max_size 25M
upload_max_filesize 25M

3) Expand the php.ini template by typing:
/sbin/e-smith/expand-template /etc/php.ini

4) The most important task:
Restart the httpd service, or if you don't know how, reboot your SME Server.
I learned the hard way that none of your changes would take effect until you restart it.
If you choose to restart the httpd service, you may also need to start the httpd-admin service; I noticed that it doesn't come un by itself (but I could be wrong about this).

Thanks to everyone who helped. This script is really nice...
Someone with PHP skills please write a front end to manage users, rights, and other necessary tasks. I started learning PHP but had to stop, because I had other priorities. But no doubt, PHP rulez!

Mark Thomas

Re: Allow Write Access to I-Bay Account - Download issue on
« Reply #28 on: September 18, 2003, 04:36:36 AM »
So far this is what I have done to get 'webFileBrowser'
(http://www.webfilebrowser.org/) working, *somewhat*, on SME
6beta3.

To enable uploads I changed @copy to @move_uploaded_file on
line 1146 in the webFilebrowser.php file.

 if (@move_uploaded_file($HTTP_POST_FILES["file"]["tmp_name"], $fp)) {

To *try* to enable file upload sizes larger than 2MB I added
/php.ini to the templates-custom area.

etc/e-smith/templates-custom/etc/php.ini

I then added the following files to it.

 20ResourceLimits
 40DataHandling
 60FileUploads

I edited each one changing the values below.
 
MaxExecutionTime 1800
MemoryLimit 100M
PostMaxSize 25M
UploadMaxFilesize 25M

I restarted httpd with
service httpd restart
(I also rebooted the server)

I tried changing the value of 'uploadmaxsize' in the
webFileBrowser.php file to 2621440.

I also performed these commands. Which appear to edit the
php.ini file itself.
/sbin/e-smith/config setprop php MaxExecutionTime 1800
/sbin/e-smith/config setprop php MemoryLimit 100M
/sbin/e-smith/config setprop php PostMaxSize 25M
/sbin/e-smith/config setprop php UploadMaxFilesize 25M

Expand the template:  /etc/e-smith/events/actions/conf-php

So far I am *unable* to upload files larger than about 1M.

Note:
I have another 'webshare' installed which *will* accept
uploads of 25M or less.

p.s.
In the docs I read (http://www.e-smith.org/custom/) it said;
--
Expand the template:

     /sbin/e-smith/expand-template /etc/smb.conf

When you've finished, the new changes will appear in the /etc/smb.conf file
--

If that's the case, shouldn't changing the values in the
templates-custom/php.ini/ change the etc/php.ini file?

Amazing Iceman

Re: Allow Write Access to I-Bay Account - Download issue on
« Reply #29 on: September 18, 2003, 08:48:47 AM »
You didn't need to use this commands I you use the templates:

/sbin/e-smith/config setprop php MaxExecutionTime 1800
/sbin/e-smith/config setprop php MemoryLimit 100M
/sbin/e-smith/config setprop php PostMaxSize 25M
/sbin/e-smith/config setprop php UploadMaxFilesize 25M

And I think you made a mistake here:
"I tried changing the value of 'uploadmaxsize' in the
webFileBrowser.php file to 2621440."   <== This is about 2.4 MB, not 26MB !!!


Check your /etc/php.ini file, make sure that the parameters were properly changed by the templates. If you have duplicates, then something went wrong.
Copy again the template, and change the values again; maybe you deleted something the first time. Even a missing ";" could cause the template to fail.

- Mine seems to be working good. I want to experiment with really large files, and tweak PHP to allow resuming file transfers in case of a communication failure.
I want to try 700MB files to see what happens.