Sponsored Content
Full Discussion: File upload message in SFTP
Top Forums Shell Programming and Scripting File upload message in SFTP Post 303023420 by Azrael on Sunday 16th of September 2018 02:42:03 PM
Old 09-16-2018
Unsure if this is coming from an sFTP client, or a script that calls sFTP. If it is a script, it would probably benefit to post the code here. Otherwise that's probably an issue with the sFTP client or the server. Unless you wish to look and re-write the code of the client or server, you're probably better off to just do an 'ls' after the file is uploaded. Or do something like 'ls -ld filename' in the script after the file is uploaded to check.

Hope that helps.
 

10 More Discussions You Might Find Interesting

1. Solaris

sftp error message VREY VERY URGENT

when one custmer connect using sftp got the following delivery report can you plase suggest on the issue. 14:04:36 SFTP Delivery properties: Host: <ip> Target Folder: </home> User: <user> 14:04:36 Keys loaded succeffuly 14:04:36 GEN-E-GENERAL, Error connecting to server : Invalid... (6 Replies)
Discussion started by: GIC1986
6 Replies

2. Shell Programming and Scripting

sftp file upload problem

Hi All, I am trying to upload a text file from HP unix to Windows tectia server using sftp, the text file shows with new line character after upload. For EG : abc.txt file contains 123 456 aftre upload it shows as 123 456 i am using sftp version 2.0 TQ, (4 Replies)
Discussion started by: phani1312
4 Replies

3. Shell Programming and Scripting

How to Write sftp through "expect" for file upload ?

Hi Experts , I am new to unix programming please tell me how to write expect and hoe to call it for automated file upload process. help me really ! (0 Replies)
Discussion started by: kulbhushan
0 Replies

4. Ubuntu

I want to upload file on remote machine in noninteractive mode through SFTP

Hi All, I want to upload file through SFTP in non interactive mode on remote server. please tell me what will have to do in oreder to do SFTP . (1 Reply)
Discussion started by: kulbhushan
1 Replies

5. UNIX for Advanced & Expert Users

chrooted SFTP upload folder

Hi List, I have set up a chrooted SFTP setup following the instructions I found on tech republic: /blog/opensource/chroot-users-with-openssh-an-easier-way-to-confine-users-to-their-home-directories/229 I have successfully got it all working and I can download files when logged in via sftp... (0 Replies)
Discussion started by: landossa
0 Replies

6. Shell Programming and Scripting

help to upload multiple files through SFTP

Hi Experts, Please help me to write the expect script for uploading multiple files in one shot . Below is my program that I have written. #!/usr/local/bin/expect -f #/home/kulbhushan/sftp_prog.sh # procedure to attempt connecting; result 0 if OK, 1 otherwise proc connect {passw} { expect... (1 Reply)
Discussion started by: kulbhushan
1 Replies

7. Shell Programming and Scripting

Expect Script for SFTP Upload

I am attempting to utilize an expect script (that is called from a parent bash script) to perform a file transfer over sftp. The script works except I cannot catch timeouts. I need to be able to tell in the parent bash script when the expect script has timed out, or completed successfully. It... (3 Replies)
Discussion started by: thaller
3 Replies

8. Shell Programming and Scripting

blocking connection message in sftp

when i use below sftp command we get connectuiobn message , is there a way to block it. cnt=`sftp -b 'count.sh' <username>@<password>:/gsmtmeg1/java5/docs/common/ | grep -v '^sftp>' | wc -l`;echo $cnt Output ** RESTRICTED ACCESS ** You are authorized to use this system for approved... (0 Replies)
Discussion started by: lalitpct
0 Replies

9. Shell Programming and Scripting

Generate file and Upload to SFTP server.

Xperts, My requirement is something like this, I have a sql script which i need to embed in a shell. The sql (oracle) script will generate a .csv file in some Unix directory. the approximate file size is around 10 mb which i need to upload to an sftp server. My concern here is how to make... (5 Replies)
Discussion started by: Showdown
5 Replies

10. UNIX for Dummies Questions & Answers

[Solved] ls -l in CentOS 6.4 after upload using sftp

Hi everyone, Something rather interesting just happened to me. I uploaded a file to a server through sftp. I closed the connection and then logged on to the server via ssh. So far so good. When I typed ls -l in the remote server to retrieve a directory listing, the file that was previously... (2 Replies)
Discussion started by: gacanepa
2 Replies
MONGOGRIDFS.STOREUPLOAD(3)						 1						MONGOGRIDFS.STOREUPLOAD(3)

MongoGridFS::storeUpload - Stores an uploaded file in the database

SYNOPSIS
public mixed MongoGridFS::storeUpload (string $name, [array $metadata]) DESCRIPTION
PARAMETERS
o $name - The name of the uploaded file(s) to store. This should correspond to the file field's name attribute in the HTML form. o $metadata - Other metadata fields to include in the file document. Note These fields may also overwrite those that would be created automatically by the driver, as described in the MongoDB core documentation for the files collection. Some practical use cases for this behavior would be to specify a custom chunkSize or _id for the file. Note The filename field will be populated with the client's filename (e.g. $_FILES['foo']['name']). RETURN VALUES
Returns the _id of the saved file document. This will be a generated MongoId unless an _id was explicitly specified in the $metadata param- eter. Note If multiple files are uploaded using the same field name, this method will not return anything; however, the files themselves will still be processed. ERRORS
/EXCEPTIONS Throws MongoGridFSException if there is an error reading the uploaded file(s) or inserting into the chunks or files collections. CHANGELOG
+--------+---------------------------------------------------+ |Version | | | | | | | Description | | | | +--------+---------------------------------------------------+ | 1.2.5 | | | | | | | Changed second parameter to an array of meta- | | | data. Pre-1.2.5, the second parameter was an | | | optional string overriding the filename. | | | | +--------+---------------------------------------------------+ EXAMPLES
Example #1 MongoGridFS.storeUpload(3) HTML form example Suppose you have the following HTML form: <form method="POST" enctype="multipart/form-data"> <label for="username">Username:</label> <input type="text" name="username" id="username" /> <label for="pic">Please upload a profile picture:</label> <input type="file" name="pic" id="pic" /> <input type="submit" /> </form> If you wanted to store the uploaded image in MongoDB, you could do the following in the script handling the form submission: <?php $m = new MongoClient(); $gridfs = $m->selectDB('test')->getGridFS(); $gridfs->storeUpload('pic', array('username' => $_POST['username'])); ?> SEE ALSO
MongoGridFS.put(3), MongoGridFS.storeBytes(3), MongoGridFS.storeFile(3), MongoDB core docs on GridFS. PHP Documentation Group MONGOGRIDFS.STOREUPLOAD(3)
All times are GMT -4. The time now is 04:51 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy