Ubuntu :: Determine When Shell Is Being Run In An Emulated / Virtual Terminal?

Apr 17, 2011

In a shell script. And use that in a condition.
Something like:

Code:
if(pts) echo "emulated"
if(tty) echo "virtual"

View 3 Replies


ADVERTISEMENT

Slackware :: Determine Native Screen Resolution From Shell?

Sep 17, 2010

Is there a way to determine the native resolution of the current console display device from the shell?

I know I can get the current console settings, but I'm looking for the native screen size of the display hardware, whether or not it conflicts with settings.

View 6 Replies View Related

Ubuntu :: Bash: Determine If Running In Terminal?

Jul 10, 2010

I'm writing a bash script to move files around based on various bits of metadata. For a few reasons, this script will be run regularly both from the terminal, and from the nautilus-scripts folder ("graphically", if you will). What I'm stumped on is having the script defer outputs based on which mode the script is running in. For example, how can I have the script know whether to echo error statements, or pump them out to zenity based on the method of invocation?

View 2 Replies View Related

General :: Determine Number Of Rows And Columns Of File In Shell?

Mar 4, 2010

if there's a tab-delimited file under /usr/desktop, how can I determine the number of rows and columns of the file in shell?And, if told the the 3rd column of the file contains only numerical values and all values in the 5th column are unique, how can I verify these in shell?

View 13 Replies View Related

Fedora :: Determine Optical Disc Type From Terminal?

Feb 3, 2010

From the terminal, or a script, how can I determine the media type (CDDA, DVD, ISO, etc) of a mounted optical disc? I need this for an automated script on my headless media server - Fedora 12 64bit.

View 2 Replies View Related

Ubuntu :: Can't Ping Emulated Routers In GNS 0.7.4 10.04

Aug 20, 2011

I`m using GNS3 v 0.7.4 under Ubuntu 10.04 to emulate Cisco devices. I face a problem no communication between emulated devices. Currently I have two routers configured and ping between them doesn`t work.

Part of log file:
Aug 20 22:14:53.911 CPU0: PCI: read request at pc=0x60603f34: bus=0,device=7,function=0,reg=0x00
Aug 20 22:14:53.911 CPU0: PCI: read request at pc=0x60603f38: bus=0,device=7,function=0,reg=0x00

[Code]....

View 2 Replies View Related

Ubuntu / Apple :: How To Boot With EFI And Not Emulated BIOS

Jan 31, 2010

I might be going Back To linux after i relearn a bit and understand it more. Now i need to understand something first, How can i get Linux to boot with EFI and not Emulated BIOS?

View 2 Replies View Related

5 :: Can Windows 7 Transparency / Translucency Be Emulated In CentOS

Jan 15, 2010

If possible I'd like to have the translucent/transparent windows that Windows 7 has, on CentOS. Is this possible and if so, how?

View 6 Replies View Related

Ubuntu :: Test Gnome 3.0 Shell On Virtual Box?

Oct 22, 2010

I have ubuntu 10.10 desktop .. and i wanna try The new Gnome shell?

View 4 Replies View Related

General :: Determine What Gnome Desktop Number A Gnome Terminal Is Connected To?

Apr 29, 2010

In KDE's Konsole, I can do the following from the terminal:

dcop kwin KWinInterface currentDesktop

And it will tell me which desktop my terminal is connected to ( per [URL])

How can I determine what desktop number the current gnome terminal in a gnome session is connected to?

View 1 Replies View Related

Ubuntu :: Shell Script To Shutdown Virtual Machines. Copy, And Than Start VM?

Mar 16, 2011

I need to make my 1st ever script to backup VMware workstation VMs to a folder which is then backed up offsite.Here is what I have so far (will be croned):

Code:
sudo vmrun -T ws stop "/home/gareth/vmware/NagiosWeb/NagiosWeb.vmx" soft
sudo vmrun -T ws stop "/home/gareth/vmware/UbuntuBackup/UbuntuBackup.vmx" soft

[code]....

View 1 Replies View Related

Ubuntu :: Shell Command For Finding All Packages That Provide A Certain Virtual Package?

Jul 29, 2010

I want to get a list of all packages that provide a certain virtual package. A way of doing this would be to write a shell script that parses all output of Code: apt-cache search -f .* And spits out all packages that have the virtual package in the provides section. The problem with this approach is that it takes an awful long amount of time to execute. I guess that there should be a simple command that does this in an efficient manner, but which I wasn't able to find.

View 1 Replies View Related

Programming :: Pseudo Virtual Files In Shell Script?

Jan 30, 2010

Perl has the concept of pseudo virtual files where data can be appended to the end of the script, & Perl will treat it as a legitimate source of data:

Code:
$ cat pseudo_file.pl
#!/usr/bin/env perl
use strict;
while (<DATA>) {
print; }

__DATA__
1
2
3
$ perl pseudo_file.pl
1
2
3
$ _

I would really like to be able to do something similar in a Bourne shell script where I don't have to manage a collateral text file which is prone to getting lost. Does anyone know if there is a similar construct in shell programming? I would have thought this feature was a remnant that Perl inherited from its shell programming roots, but searching on the Web has revealed nothing of consequence.

View 11 Replies View Related

Ubuntu :: Switching Out Of First Virtual Terminal

Nov 2, 2010

If I enter my first virtual terminal with ctrl + alt + F1, how would I get back to my GUI.

View 7 Replies View Related

Ubuntu :: Is There Any Way To Lock Virtual Terminal?

May 6, 2011

Metacity can be locked, but what about a logged-in session in a virtual terminal?

View 3 Replies View Related

Ubuntu :: How Do I Turn Off Beep In Virtual Terminal

Feb 9, 2010

I'm running ubuntu 9.10 on a Dell XPS M1530. Sometimes i get a _VERY_ loud beep-sound, eg when i run out of battery or, the case that has me coming here when i'm working in a virtual terminal (tty1-6) and hit backspace once too often, that is, when the command line is actually empty.Not that big of a deal you might think, but, especially when you're wearing good (read: possibly loud) headphones the experience is that god damn unpleasant that i'd like to make sure it won't happen again.Oh and well, just hitting mute (in gnome, which doesn't have a lot to do with tty1 anyways) won't do the job.

View 2 Replies View Related

Ubuntu :: Listen To Music Via Virtual Terminal?

May 27, 2010

I imagine I'll have to install something, but Google has shed no light for me thus far. And just to clarify, when I say virtual terminal I mean the terminals accessed by CTRL+ALT+(F1-F6). I'm going to be doing a challenge/learning experience where I don't allow myself a graphical interface for a month. way around BASH through adaption. However, if I have to go a month without music I will go insane.

So, even if this is possible can I listen to music from the internet (....., playlist.com, etc.) or just music on my hard drive? And I'm not sure if this thread belongs in Desktop Environments or not, that section seemed to focus on graphical interface.

View 9 Replies View Related

Ubuntu :: Virtual Terminal's Text Overlapping?

Aug 20, 2010

I cannot have any more than 47 characters on each line of my virtual terminal without everything on that line disappearing. The text is apparently still there, since commands that need more than 47 characters still work but the text stays hidden. After the text has been overlapped I can type as many characters as I like and it no longer overlaps, but my PS1 on that line and all previously overlapped text stays hidden.I'm almost certain that the problem is in my bash configuration since it happens in a terminal emulator as well as the virtual terminal.

View 2 Replies View Related

Ubuntu :: Test Virtual Terminal Resolution ?

Apr 1, 2011

How to change the resolution of a VT, but nothing on how to find out what it is?

So what is it?

Code:

outputs (for example)

Code:

View 1 Replies View Related

General :: Shell Script To Shutdown Virtual Machines / Copy And Than Start VM?

Mar 16, 2011

I need to make my 1st ever script to backup VMware workstation VMs to a folder which is then backed up offsite. Here is what I have so far (will be croned):

Code:

sudo vmrun -T ws stop "/home/gareth/vmware/NagiosWeb/NagiosWeb.vmx" soft
sudo vmrun -T ws stop "/home/gareth/vmware/UbuntuBackup/UbuntuBackup.vmx" soft
**copy or rsync to /home/gareth/vmware-backup/ dir**

[code]....

1. Just to confirm, I need to place the above in a file with #!/bin/bash at the top and make it executable.

2. How do I know when the VMs have safely shut down so I can start the copy? I guess I can either a. wait a specified amount of time b. run some sort of if statement to confirm they are off.

3. How do I use Rsync or cp to copy to the backup folder?

4. How will I know the copy is complete so that I can start the VMs again?

View 3 Replies View Related

Ubuntu :: Keyboard CAPS Led Not Light Up In Virtual Terminal?

Feb 10, 2010

It does in jaunty.....

Code:
00:00.0 Host bridge: Intel Corporation Mobile PM965/GM965/GL960 Memory Controller Hub (rev 0c)
00:01.0 PCI bridge: Intel Corporation Mobile PM965/GM965/GL960 PCI Express Root Port (rev 0c)
00:1a.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #4 (rev 02)
00:1a.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #5 (rev 02)
00:1a.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #2 (rev 02)
00:1b.0 Audio device: Intel Corporation 82801H (ICH8 Family) HD Audio Controller (rev 02)
00:1c.0 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 1 (rev 02)
00:1c.1 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 2 (rev 02)
00:1c.3 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 4 (rev 02)
00:1d.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #1 (rev 02)
00:1d.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #2 (rev 02)
00:1d.2 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #3 (rev 02)
00:1d.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #1 (rev 02)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev f2)
00:1f.0 ISA bridge: Intel Corporation 82801HEM (ICH8M) LPC Interface Controller (rev 02)
00:1f.1 IDE interface: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) IDE Controller (rev 02)
00:1f.2 IDE interface: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) SATA IDE Controller (rev 02)
00:1f.3 SMBus: Intel Corporation 82801H (ICH8 Family) SMBus Controller (rev 02)
01:00.0 VGA compatible controller: nVidia Corporation G84 [GeForce 8600M GT] (rev a1)
03:00.0 Ethernet controller: Broadcom Corporation BCM4401-B0 100Base-TX (rev 02)
03:01.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 05)
03:01.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 22)
03:01.2 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 12)
03:01.3 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev 12)
0c:00.0 Network controller: Broadcom Corporation BCM4312 802.11b/g (rev 01)

View 3 Replies View Related

Ubuntu :: Change Virtual Terminal Colors Before Logging In?

Apr 17, 2011

I put

Code:
echo -e 'e[0;34m'

into /etc/profile, but it still doesn't work until I login. I'd like it to work before that, so that all messages (like those displayed on boot up) have these default settings.

View 6 Replies View Related

General :: Secure Shell/terminal For Ubuntu?

Jul 22, 2010

There are a couple commands I want to run in a terminal that require me to provide my password. I really don't want those commands ending up in any kind of history or anywhere else where they could be seen by someone after the command was run. Are there any shells/terminals for Ubuntu that I could use (or options to bash/zsh/etc) that would give me a secure environment where I don't have to worry about my history being kept?

View 3 Replies View Related

Ubuntu :: Running Shell Script From Terminal?

Feb 14, 2011

I have a shell script that I want to be able to run from the terminal just by typing "topcat", regardless of where I am or what user I'm under. How would I go about changing the bash configuration files (if I have to) in order for that to work, for me and for the other users on the computer (I have root access)? As it stands right now, I have to type "/bin/topcat/./topcat" in order for it to execute

View 3 Replies View Related

Ubuntu :: Gnome-terminal Not A Login Shell / Why Is So?

Mar 3, 2011

I've seen lots of posts all over the Internet that advise users to check the "Run command as a login shell" checkbox in GNOME Terminal under Edit->Profile Preferences->Title and Command.

This makes gnome-terminal run bash/csh/tcsh/ksh as a login shell, which it does not do by default. In turn, running gnome-terminal as a login shell sources the system and user login scripts. This sets up things like colored ls etc.

It seems like gnome-terminal should be a login shell by default. Why isn't it? I've never seen a good explanation of why gnome-terminal isn't a login shell. The "Run command as a login shell" checkbox must be unchecked by default for some good reason, right?

View 1 Replies View Related

Ubuntu :: Karmic Virtual - Can See Text Under Semi-transparent Terminal

Jan 4, 2010

I have just installed 9.1 and I like to use a semi-transparent terminal so i can see text under it, but on Karmic, it shows the desktop background underneath.

View 3 Replies View Related

Ubuntu Servers :: 10.04 Server Virtual Terminal / Display Not Working

May 4, 2010

Clean install of 10.04 Server 32 bit.Only services OpenSSH Server and Print Server.Machine boots and can be accessed through ssh.Virtual terminals (cntl-alt-1,2,3,4,... do not result in video to the monitor (no sync) or a display.If I type blind, I can log in, ssh back to my other machine, and create a file. So the virtual terminal is there and listening to the keyboard and running, just not creating a display.

This machine has been working fine with 08.10 for quite time up until yesterday, so I don't believe it is a hardware problem.Any ideas why the video on the virtual terminals would not work?

View 8 Replies View Related

Ubuntu :: Lock Virtual Terminal Without Quitting The Current Program?

May 26, 2011

vlock works, however it requires that I return to the shell to run it. Is there a way to assign a key combination to run vlock, so the current program doesn't have to be ended?

View 3 Replies View Related

Debian Configuration :: How To Set Virtual Terminal Color

Dec 30, 2015

I am a newer to debian. I want to change the color of the vitrual terminal. I have found the function " setvtrgb ",but I don't know how to mix the color , Only text green and background black...

View 10 Replies View Related

Software :: How To Swap Right Alt And Right Control For Virtual Terminal?

Jan 10, 2011

My emacs 23 is running on Ubuntu 10.04 and I am very a emacs primer. in virtual terminals, how can I remap keys to swap the right alt key and the right ctrl key automatically every time the machine starts up? But how to swap Alt and Ctrl on the right side?

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved