/dev/console file


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers /dev/console file
# 1  
Old 03-02-2005
Question /dev/console file

Hello,
I am fairly new to UNIX. I ran command tty on my shell prompt and it return me /dev/console.

I was reading in the book that normally output of tty command is tty01 , tty02 or so on.

My question is this is the file for my monitor? UNIX called it Terminal or Workstation?

What is this file's extension ? and what is in this file cosole file?

Can I read the contents of console file?

Thanks for any response.

Abid Malik
Raligh, NC
# 2  
Old 03-02-2005
If you had been on system A and used ssh/telnet/rlogin to go to system B and tried that command, you would have gotten the expected result.

Since you were on the console of the system, /dev/console was returned. It is, simply, the 'terminal' associated with the monitor attached directly to the server.

You can find more information by reading the man pages for the following commands and then trying those commands (you should always have an understanding of what a command will do before attempting to use it).

$ man file
$ man ls
$
$ ls -l /dev/console
$ file /dev/console
# 3  
Old 03-02-2005
Thanks

Thanks RTM,
But you did not tell me what is in this file? Can I view this file?

AM
# 4  
Old 03-02-2005
No, I didn't tell you what is in the file - but - I did give you commands to check out so you can find out what's in the file and if you can 'view it'. Consider this a educational experience.
# 5  
Old 03-02-2005
Thanks RTM,
I have got it now.

AM
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Red Hat

Changing grub from /dev/sda to /dev/sdb

Hi, Please suggest steps to change grub from /dev/sda to /dev/sdb, (1 Reply)
Discussion started by: manoj.solaris
1 Replies

2. Shell Programming and Scripting

Automating partitioning setup of /dev/sda on /dev/sdc

Objective: To recreate the partitioning setup of /dev/sda on /dev/sdc How would I parse the below information and initialize variables (an array?) that can be used to build sgdisk commands in a script, regardless of the number of partitions? Something along the lines of: sgdisk -n... (12 Replies)
Discussion started by: RogerBaran
12 Replies

3. Solaris

Lun remove, stuck in /dev/dsk and /dev/rdsk

So, we removed a LUN from the SAN and the system is refusing to remove the references to it in the /dev folder. I've done the following: devfsadm -Cv powermt -q luxadm -e offline <drive path> luxadm probe All those commands failed to remove the path. The drive stills shows up as <drive... (13 Replies)
Discussion started by: DustinT
13 Replies

4. Solaris

Hang when run command with /dev/console

hi guys, I don't know why I run this command: echo a>/dev/console It is not responsed from console and hang. If I run echo a>/dev/null, it is OK. here it is the console file: mcl1101 root#ls -ltr /dev/console lrwxrwxrwx 1 root other 30 Aug 18 2009 /dev/console ->... (4 Replies)
Discussion started by: caspian
4 Replies

5. Emergency UNIX and Linux Support

Capturing console (/dev/ttyS1) logs

Hi, I have been trying to capture console logs from the init script. When the ramfs is mounted, i check if usb is connected , if conncted, i mount it and redirected the console logs like so: cat & /dev/ttyS1 >> /mnt/logs.txt I'm getting /bin/sh : /dev/ttyS1 :permission denied ... (8 Replies)
Discussion started by: xerox
8 Replies

6. Shell Programming and Scripting

Redirecting standard out to /dev/null goes to file "/dev/null" instead

I apologize if this question has been answered else where or is too elementary. I ran across a KSH script (long unimportant story) that does this: if ; then CAS_SRC_LOG="/var/log/cas_src.log 2>&1" else CAS_SRC_LOG="/dev/null 2>&1" fithen does this: /usr/bin/echo "heartbeat:... (5 Replies)
Discussion started by: jbmorrisonjr
5 Replies

7. UNIX for Advanced & Expert Users

console /dev/console get image

We are using software (Pegasys) which runs on SunOS 5.8 and reads images from a Philips nuclear camera. The software is designed to run from the console. I need to be able to capture the images it produces on the display. The caveat is that I cannot use the X Windows display because the X Server... (3 Replies)
Discussion started by: sreyes27
3 Replies

8. BSD

Logging to /dev/console

Hi, The output of the cat ttys on a free BSD m/c console none unknown off secure # # Serial terminals # The 'dialup' keyword identifies dialin lines to login, fingerd etc. ttyd0 "/usr/libexec/getty std.9600" unknown on secure ttyd1 "/usr/libexec/getty std.9600" dialup off ttyd2... (0 Replies)
Discussion started by: mlalitha
0 Replies

9. Solaris

script hangs when outputing to /dev/console

I am running solaris 8 on a sparcs box. The system is connected to a lightwave console server. I have a script that hangs when sending output to '/dev/console'. Any ideas? -V (2 Replies)
Discussion started by: vada010
2 Replies

10. Solaris

What is /dev/tty /dev/null and /dev/console

Hi, Anyone can help My solaris 8 system has the following /dev/null , /dev/tty and /dev/console All permission are lrwxrwxrwx Can this be change to a non-world write ?? any impact ?? (12 Replies)
Discussion started by: civic2005
12 Replies
Login or Register to Ask a Question