UUCP Transfer Files to Old UNIX Computer


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers UUCP Transfer Files to Old UNIX Computer
# 22  
Old 07-24-2013
Quote:
You forgot the 9600,
Sorry, typo on the my post.
With the command
Code:
stty -F /dev/ttyS0 9600

, There is no output message. The cursor moves to the next line ready for the next command.

When I run the command on the UNIX system
Code:
stty 9600 < /dev/tty00s

the cursor moves to the next line, but there is no command prompt #. I don't know what the exact term for this is, but I can still type to the screen and press enter, but there is no command processed. This probably means that /dev/tty00s isn't the correct serial port, right?
# 23  
Old 07-24-2013
It may mean it's having trouble opening the serial port -- that the shell tries to open it to redirect into it, and is stuck waiting for it to become ready.

It may need the cable to be plugged in. It may even be waiting for the other end to be ready. And, of course, it may be the wrong port.

Last edited by Corona688; 07-24-2013 at 07:11 PM..
# 24  
Old 07-24-2013
I tried stty with all 4 of my tty files. It seems to pass the command with no message if I use tty, but the other 3 stop and wait. If I press delete on either of those three, I get the message
Code:
/dev/tty00s: could not open

.

An interesting thing did happen. I had Ubuntu run
Code:
cat /dev/ttyS0

while I tried some of the echo commands within UNIX. I switched my monitor (working with one monitor, makes it a little more difficult) and I guess the graphics had crashed on Ubuntu. I told it to run in low graphics for this session. It went to a command prompt to reload the graphics, and one line said this
Code:
Stopping System V runlevel compatibility

I don't know if this is standard with Ubuntu, or if it was set up to talk to UNIX. It makes me think that Ubuntu is reading UNIX, but I'm not using the correct device file within UNIX.

edit....
There is another tty file called systty. It seems to behave much like the file tty.
# 25  
Old 07-25-2013
/dev/tty is a special device that ends up just pointing to your own terminal.

You are opening these files with the cable plugged in and the other end trying to write?

Could these ports be in use already on your UNIX machine, for login prompts or something?
# 26  
Old 07-25-2013
The cable is plugged in to both computers. I'm not real sure if the ports could be in use or not. I don't see how they could be used for login prompts, as it is a standalone computer on no network.
These are the exact steps I have been taking...

Log onto both computers.
On Ubuntu, I run from a root user terminal
Code:
stty -F /dev/ttyS0 9600

I receive no message, so I assume the command went through.
I then swap to UNIX, logged in as root, and run
Code:
stty 9600 < /dev/tty00s

The screen then goes to the "waiting mode" with no real prompt, only a cursor. If I press DEL, I receive the message
Code:
/dev/tty00s: cannot open

I tried that command using tty00h and tty00 as well. I pressed DELETE after a couple seconds, how long should I wait for it try to connect?

Correct me if I'm wrong, but I think of the commands like this.
Code:
stty -F /dev/sttyS0   |   stty 9600 < /dev/stty00

This attempts to open said devce and connect to the computer on the other end of cable to set up communications.

Code:
cat /dev/ttyS0    // From Ubuntu, Opens ttyS0 for reading

Code:
echo "Hi" > /dev/tty00h   // From UNIX, Write "Hi" to tty00h. "Hi" should appear on other Ubuntu screen

# 27  
Old 07-25-2013
Quote:
Correct me if I'm wrong, but I think of the commands like this.
Okay.

It does not prepare one end for reading and the other for writing. It sets the baud rate on the serial port so that they can send letters to each other instead of gibberish.

It has to open the device file to do so, though! And depending on how it's configured, it may be waiting for some signal line or other to be set 'ready' on the far end.

Serial ports have the ability to tell each other when they're ready. Hardware flow-control means "if this bit on the serial port isn't active, wait before sending more data". It may be waiting for that bit to be set before letting you open the port. It's possible to turn off this flow control, probably, but to do so you have to open the port! Grrr. I take it your UNIX system has nothing for 'man stty'.

So when I say 'writing' I mean that literally. After you do 'stty -F /dev/ttyS0 9600' on Ubuntu, do 'echo asdf > /dev/ttyUSB0' to set that bit, so that it knows there's something on the other end. Ubuntu may wait too, until the other end is open, to send the data.

And, of course, we have no idea if you're even opening the right device Smilie

Last edited by Corona688; 07-25-2013 at 02:29 PM..
# 28  
Old 07-26-2013
Because I did a lot of service work with equipment running serial ports my diagnostics included a laptop with a terminal emulator looking at the signals crossing between machines. Only used the Rx and common lines and could connect to the Tx of either side. Trying to figure out what is going on with 2 not communicating can be impossible and a known quantity can help.

Also helped that the laptop dual booted either unix or dos and could be used to emulate either end for testing purposes.

YMMV
 
Login or Register to Ask a Question

Previous Thread | Next Thread

8 More Discussions You Might Find Interesting

1. Solaris

Need to transfer files between 2 UNIX servers, with same folder permission

I need to transfer directories/files between 2 Unix servers, with same folder permission. I tried scp, but it retains the the permissions, but changes the owner of the directory/file to the user used to copy them to the destination. I don't want that to happen. If possible without any other... (6 Replies)
Discussion started by: Pandee
6 Replies

2. Shell Programming and Scripting

Shell Script to transfer files from unix to windows

I have to transfer a file from unix to windows through Shell Script. I am using the below script, but it is not working. Please help. Please note --- I have to transfer the file from unix to windows. Not from windows to unix. I mean I don't have to use batch script.Only through unix shell script.... (1 Reply)
Discussion started by: vsachan
1 Replies

3. UNIX for Dummies Questions & Answers

UUCP (Unix to unix copy) not working

I have a problem using uucp. I have Ubuntu 10.4 and i installed the 'uucp' package. In my LAN there are a desktop pc, a laptop, and the router the desktop local ip is: 192.168.0.2 the laptop local ip is: 192.168.0.4 Here are the /etc/uucp/config and the /etc/uucp/sys i used on the desktop.... (4 Replies)
Discussion started by: mghis
4 Replies

4. UNIX for Advanced & Expert Users

How to transfer files from Unix to Windows.

Hi There is a requirement for me to transfer files from Unix to windows in an automation process of unix. Please let me know is it posibble to shell scripting this? Could you help me in scripting it? Regards Venugopal (2 Replies)
Discussion started by: venu_eie
2 Replies

5. Shell Programming and Scripting

shell script to transfer files from Unix to Windows

I need to write a shell script to transfer files from Unix server to windows machine. This script will be scheduled on scheduler to run at specified intervals #!/bin/ksh ftp -n alaska <<End-Of-Session user sss01 sample cd /home/sss01 lcd D:/sample mget *.txt bye when I executed the... (15 Replies)
Discussion started by: knag
15 Replies

6. UNIX for Dummies Questions & Answers

Transfer files from Unix server to Windows using FTP

Dear Friend, I don't know much about unix.I am an VB6.0 Programmer.I need to move an text files as aaa.txt from unix server to windows "D: " driver using the FTP protocol.Is it possible to do this with help of unix shell script.If possible please give some sample codes. Please answer as early... (1 Reply)
Discussion started by: gjsaravanan
1 Replies

7. Shell Programming and Scripting

uucp (UNIX) problem

Hi ! I couldnot execute Unix uucp command for copying file from Unix to Unix machine, whenever I am using the following command : $uucp file_name system!/destination Error is "Bad System Name" Let me know the way. From, Niraj Gopal Sharan (2 Replies)
Discussion started by: Niraj Gopal Sha
2 Replies

8. Shell Programming and Scripting

transfer of files via ftp from windows to unix

I am currently looking to write a script to transfer files from a windows NT server to a unix server any ideas of how to go about this? (1 Reply)
Discussion started by: chambala5
1 Replies
Login or Register to Ask a Question