Tag Info

Hot answers tagged

13

You can use rsync to copy your file from one computer to the other. rsync can use ssh as its underlying transport. Combine rsync --partial with a script such as this one to try again in case of network failure, and you should be able to move your files even in the face of network errors. Another way to do it would be to mount the remote filesystem on your ...


10

You should be able to do this using something like: server { server_name example.com; client_max_body_size 10m; # or whatever size limit you want error_page 413 /custompage.html; # you can also use a named location here if you like } http://wiki.nginx.org/HttpCoreModule#client_max_body_size http://wiki.nginx.org/HttpCoreModule#error_page


7

Two problems: First, the * does not go on the destination side. Second, -r is for copying an entire directory and subdirectories. pscp -i C:\sitedeploy\abt-keypair.ppk includes\* root@mysite.com:/usr/local/tomcat/webapps/ROOT/includes/ Will copy all of the files in the local includes\ directory to the .../includes/ directory on the server. pscp -r -i ...


6

rsync does exactly that in the default transfer mode: it creates a new file on the destination for the duration of the transmission and renames it after the transmission completes. Nontheless, this will not help with situations where your upload is "inconsistent" - i.e. you have uploaded files which depend on other, not yet uploaded files. If this is a ...


5

I'd say the safest solution to this is to generate a password-less SSH-key for each machine and add it to the authorized_keys list on the other. On machine 1 (as the user who's logging on to the other server): $ ssh-keygen -t rsa $ ssh-add ~/.ssh/id_rsa $ cat .ssh/id_rsa.pub If keygen asks you for a password, just press enter to create a password-less ...


5

These should be installable via yum and the base RHEL repositories. Have you tried querying if they are already installed but not in your path? Also, have you successfully installed anything via yum? To check what package you need to install: [user@server]# yum whatprovides autoconf automake Loaded plugins: rhnplugin, security autoconf-2.59-12.noarch : A ...


4

You need to look out for: Maximum file size. This can be done by the web developers in many cases. Permissions. Do you want each user to have their own (virtual or real) folder that nobody else can see? Do you want users to be able to delete files they have uploaded, or even see them? They should probably be able to verify what files they uploaded at the ...


4

We use SFTP/SCP or rsync-over-SSH, but that depends on the client having the relevant client/server software at there end. It goes as fast as out links will allow, with rsync interrupted transfers are restartable, and it is all nicely scriptable (assuming you know your bash/equivalent scripting and related tools) so things can be completely automated. ...


4

There is almost always an entry recorded as long as it successfully started the request. However, the logs in C:\Windows\System32\LogFiles\HTTPERR will sometimes catch the errors that occur earlier in the pipeline. A timeout is different though and isn't an IIS error, so it should show in the logs. For log file mining, check out Log Parser. Very ...


4

It is mostly a problem if you have limited ram and multiple users doing uploads at the same time. Both of those are per session, so a user starting a slow upload can eat up quite a bit or resources for you for a long time. If you have over 40 or so users doing uploads/big posts at the maximum size you will run into problems. Otherwise it shouldn't be any ...


4

Solution: FcgidMaxRequestLen -->This is causing the problem. Before updating to the newest version, it was default set to 1gb. Now it is 128kb. Add the following to the file /etc/apache2/conf.d/fcgid.conf : FcgidMaxRequestLen 1073741824 This wil give you a limit of 1gb. Next, restart your apache.


4

Uploading a file is likely to consume almost no resources on the server. The resources that uploading a file can consume are (in probable, though not definite, order): Your outgoing bandwidth Server's incoming bandwidth Server's disk IO Server's CPU Your outgoing bandwidth is likely the problem when you report that the terminal is being slow (ceejayoz ...


3

HTTP Error 404.13 means that the IIS7 request filtering module is killing the request because the request is too large. The correct way to increase this is by configuring the maxAllowedContentLength value in the system.webServer > security > requestFiltering configuration section of your site's web.config. For example: <configuration> ...


3

Based on your real goal (I am building a web app where my user will be able to upload epubs files and I want to make sure they are no executable files.) ClamAV is probably overkill for your needs. You can use the file utility (or various APIs that hook the same database of magic data) to determine what kind of file the user is trying to upload, and reject ...


3

It depends entirely on the receiving application. Most FTP/SFTP servers would keep the partial file under the assumption that the client will resume the transfer later. SCP is about 50/50 in my experience. I assume because it's a configurable option and different distros have decided on different defaults, but I haven't actually looked in to this. Windows ...


3

scp and sftp will replace the file in-place, so yes, theoretically an HTTP client could try to fetch a partially-uploaded file. You can mitigate this by using rsync over SSH instead of sftp as this will write to a temporary file first and then replace the file. rsync can also be configured to backup any files it replaces.


3

Make sure you use incremental backups over FTP. Consider using a 3rd party backup system like R1SOFT or another system. CPanel by default will dump and tar the backups locally and use your disk before sending the files over. But using the incremental FTP option will prevent taring of the files on the local disk.


3

You don't need to download it. Just open up notepad and paste the following into the file: X5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H* Then, save it as whatever file you want. You'll probably need to temporarily turn off your AV to handle the file though.


3

Whether a Perl CGI program gets invoked or not depends primarily on the server configuration and the "path" part of the resource path. The Perl CGI script might return HTML (and usually this is the case). So requesting a script is often effectively requesting an html page, even if the URL doesn't contain ".html". If the URL is, say, ...


3

AFAIK there is no built-in support for webdav in browsers. I think there are applications and AJAX libraries you could run on your web server that would make webdav through the browser possible. A quick google search for ajax webdav showed one interesting looking product (http://www.webdavsystem.com/ajaxfilebrowser). I have never used this, just ...


3

While TCP (the protocol on which http/https is built) has error-detection in the form of a checksum on board (which triggers retransmissions), it's not bulletproof. It is very rare, but numerous bit flips in the same packet could still result in a valid checksum. If the rest of the packet is still undamaged, those errors could travel all the way into your ...


3

I do this using scp. To copy the file "foobar.txt" from the remote host to local machine: $ scp your_username@remotehost.com:foobar.txt /some/local/directory To copy the file "foobar.txt" from the local machine to the remote host: $ scp foobar.txt your_username@remotehost.com:/some/remote/directory Since you're using PuTTy (I assume from Windows), ...


3

You should also be able to do it with OpenSSH 4.9 and up, with which you can additionally chroot the user for increased security. In your /etc/ssh/sshd_config: Match User user ChrootDirectory /home/user ForceCommand internal-sftp AllowTcpForwarding no Then run: chsh -s /bin/false user chown root:root /home/user mkdir /home/user/uploads chown user ...


3

If you are needing to throttle your own applicatino then I would suggest you include daat rate limiting support in the application itself, though if you are using a 3rd party library to do the sent this may not be possible. You don't state anything about your platform and intended install environment making specific recommendations difficult, but libcurl ...


3

Most enterprise datacenters have you purchase bandwidth from them as part of the hosting package. As such you are guaranteed your bandwidth (unlike shared hosting sites where you are more likely sharing it with everyone else) but also are limited to what you've contracted for. Most will also have bursting agreements where you can use additional bandwidth ...


3

That's a pretty general question. A general answer would be "fast" :-) To put some real world numbers on it we have a 100 Mb/sec circuit going to our rack at our data center. I have run tests to servers around the internet and I have seen both my download and upload speeds peak out at over 94 Mb/sec. So to really answer you question, it's whatever speed ...


3

You can use WinSCP to perform this kind of automatic upload. It's normally used with SFTP or SCP but it supports plain FTP as well (your server may actually be capable of SFTP or SCP) and this can be automated with their automation scripting: WinSCP Automation Guide The specific command you're looking for is keepuptodate: ...


3

Keep in mind that this is a serious security risk, so you definitely want to do this in a restricted environment, running under a restricted shell or for chrooted accounts only. @Kimvais suggestion of scponly is on the right track. In the client create a .ssh/id_rsa key with an empty passphrase -- this will create an unencrypted private key. Then copy the ...


3

You could use vsftp (very secure and fast ftp-server) and setup a "secure FTP Dropbox" the relevant config parameters are: local_enable=YES write_enable=YES nopriv_user=ftp anonymous_enable=YES anon_upload_enable=YES chown_uploads=YES chown_username=inftpadm ftp_username=inftpadm local_umask=002 anon_umask=007 file_open_mode=0666 dirlist_enable=NO ...


3

1) Use SSH Public Key Authentication instead of plain-text passwords 2) Your SFTP server should allow you to limit the directories that the logged in user can access. Generally by default this is the user's HOME directory. One neat trick I found is the use of the mount --bind /new/bind/path feature. This will allow you to bind the public directory to ...



Only top voted, non community-wiki answers of a minimum length are eligible