- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Shell Script
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-08-2008 10:56 AM
тАО08-08-2008 10:56 AM
I am trying to ftp files from HP-UX server to Windows 2003 server using one of the domain account to login to windows 2003 server. Here is my script:
Domain is xyz
User is abc
Password is 123
Server name is Server1
#!/usr/bin/ksh
HOST='Server1'
USER='xyz\\abc'
PASSWD='123'
ftp -n $HOST <
quote PASS $PASSWD
lcd /test/dbdata/
cd "FTP\Dbdata"
mput *.csv
quit
END_SCRIPT
exit 0
But it throws an error stating below:
User xyz\abc cannot log in
Local directory now /test/dbdata
Please login with USER and PASS.
Thanks in advance..
vthiru
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-08-2008 10:58 AM
тАО08-08-2008 10:58 AM
Re: Shell Script
Drop the word "quote" in front of the user and password commands.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-08-2008 11:03 AM
тАО08-08-2008 11:03 AM
Re: Shell Script
I removed quote..but still getting the same error..
Thanks,
vthiru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-08-2008 11:13 AM
тАО08-08-2008 11:13 AM
Re: Shell Script
Are you sure that your USER value is correct? When I connect to a Windows' server my USER looks like "ddd/aaa" where ddd=domain and aaa=account.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-08-2008 11:21 AM
тАО08-08-2008 11:21 AM
Re: Shell Script
I think so..bcoz when I connect it manually like this
ftp -n
user
it is allowing me to login without any issues.
Thanks,
vthiru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-08-2008 11:39 AM
тАО08-08-2008 11:39 AM
Re: Shell Script
This is odd. I used your script, including the 'quote' command, and have no problems unless I supply an invalid account. Then I get:
User abc/xyz cannot log in.
Local directory now /tmp
Please login with USER and PASS.
Please login with USER and PASS.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-08-2008 12:32 PM
тАО08-08-2008 12:32 PM
Re: Shell Script
ftp -n
user
it is allowing me to login without any issues."
=================================
OK. How many "\" are in the name, and what is the *EXACT* message you are getting?
"User xyz\abc cannot log in"
it appears that you need more "\" in the variable in the script perhaps, as the name you TYPED doesn't appear to match the name in the error message you showed
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-08-2008 07:41 PM
тАО08-08-2008 07:41 PM
Re: Shell Script
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1234894
You may have to use: USER "$USER"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-09-2008 03:51 AM
тАО08-09-2008 03:51 AM
Re: Shell Script
Bcoz am able to login successfully with the account its password doesn't carry backslash. Please let me know is there any otherway I could make this script works without modifying the password.
Thanks again,
vthiru
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-09-2008 10:36 AM