Turn off screen linux

Linux Mint Forums

Welcome to the Linux Mint forums!

Turn off Display

Turn off Display

Post by abharshahic » Wed Jan 02, 2019 11:09 pm

Re: Turn off Display

Post by kato181 » Thu Jan 03, 2019 3:31 am

Re: Turn off Display

Post by abharshahic » Thu Jan 03, 2019 3:42 am

Re: Turn off Display

Post by kato181 » Thu Jan 03, 2019 5:16 am

Re: Turn off Display

Post by Hoser Rob » Thu Jan 03, 2019 8:28 am

Re: Turn off Display

Post by abharshahic » Thu Jan 03, 2019 12:21 pm

Re: Turn off Display

Post by smurphos » Sun Jan 06, 2019 5:32 am

This command works for me in a brief test on a single monitor set up.- sleep 1; xset -display $DISPLAY dpms force off; read temp; xset -display $DISPLAY dpms force on

if it works for you, you could assign it to an alternative keyboard shortcut.

Actually for me just this works. sleep 1; xset -display $DISPLAY dpms force off

Re: Turn off Display

Post by abharshahic » Mon Jan 07, 2019 3:59 pm

This command works for me in a brief test on a single monitor set up.- sleep 1; xset -display $DISPLAY dpms force off; read temp; xset -display $DISPLAY dpms force on

if it works for you, you could assign it to an alternative keyboard shortcut.

Actually for me just this works. sleep 1; xset -display $DISPLAY dpms force off

Источник

How do I completely turn off screensaver and power-management?

I looking for a method to turn-off the screensaver and powermanager but from the command line.

I’m aware this can be done via the GUI screen — but can this be done via the command line or via some configuration editor?

Here is the gui way (via the «screen» or «brightness and lock» application):

10 Answers 10

For 11.10

Disable the GNOME Settings Deamon’s power plugin from the command line:

Читайте также:  Собираем образ windows 10

Alternatively, using dconf-editor from the dconf-tools package:

For the screensaver:

Or again via dconf-editor :

You might find that the above solution is necessary, but not sufficient. The screen might still be blanking after 10 minutes. This is a default setting compiled into Xorg.

To disabled it for the current session, run:

You can put this in your .xsession file to disable it upon every login.

You didn’t specify if you want permanent solution or temporary solution. If you want to turn off screensaver and power management for e.g. 2 hours, you can simply inhibit those features.

In practice, you can simply run

As an alternative, you may want to inhibit screensaver and power management until a given process has completed. For example,

would inhibit screensaver and power management until download has finished.

See man systemd-inhibit for more details. It allows you do disable only selected features and allows setting user visible string to explain why these features are inhibited (nice if your system has multiple users).

Источник

Turn off monitor using command line

I am runnning Ubuntu Server on my laptop. There is really no reason for the screen to be on. I have been trying to use this command to turn the screen off:

The problem is I get the following error

Any idea what is going on / what is wrong? Any other suggestions for how to do this?

9 Answers 9

To turn off monitor in console, the command is the following:

To regain control of the console on pressing Enter key, I suggest

Try these commands.

If your display turns off and then immediately back on then try the following which adds a delay of 1 second before turning the screen off. This give a chance for all events to be processed by the X server before turning the display off.

The xset command mentioned in other answers will turn off all the monitors if you have multiple monitor setup. However if you want turn off only one or some of the monitor you should use xrandr .

First run xrandr -q command, which will list all the monitors and its current display settings. At the start of each monitor details you will find monitor name set by the system. You have to keep track of that.

I have two monitors (one is connected to DVI port and other to VGA port) and when I run the command I see this:

Читайте также:  Знакомство с интерфейсом linux

In this output, DVI port connected monitor is labelled as DFP1 and other one as CRT1 . So if I want turn off the secondary monitor(i.e., CRT1 ) I have run this command:

if you want switch on that monitor again then you have run this command:

Источник

Configure Ubuntu to Not Dim or Turn Off An Inactive Display

Annoying when it dims during YouTube videos

It’s typically good practice for computer users to have their displays set to turn off after a certain period of inactivity. It’s good for a couple reasons. People passing by your computer (at work, for instance), can’t immediately see what’s on your screen. Also, a monitor or display that’s turned off isn’t running, thereby saving you money on your electric bill.

Of course, there are certainly times you don’t want your display turning off. Online videos don’t always register as “activity” so even though you might be happily watching the latest YouTube opus, or playing a web browser game, you might find your display dimming at an inopportune moment.

In a previous article, we discussed a handy utility called Caffeine that keeps your computer awake if certain conditions are met. That’s a scalpel-like approach. In this article, we’ll use something a bit less refined. Here we’ll show you how to configure your power and screensaver settings so that your monitor should now only dim or turn off when you shut down your system.

The first step is to open up the control panel. In Ubuntu you can do this by accessing the System Settings option under the System menu.

You should now see a fairly standard set of control panel options.

We’ll be using the control panel called Brightness and Lock, which you’ll find (more than likely) in the top row.

You should now see something like this.

There are two settings we want to set, to ensure that our system doesn’t turn off the display after a period of inactivity, and that the screen isn’t dimmed to save power. First, untick the checkbox beside the Dim screen to save power option, as shown below.

Next, change the Turn screen off when inactive for: option to Never.

Once those two settings are configured, everything should work correctly, but you may find that not all is as it seems. In Ubuntu 12.04, this could be due to the screensaver. What screensaver? Despite all appearances, it is there, although there’s no longer a Screensaver control panel. Instead, a blank screen appears (this is different than your display turning off). To configure this, we’ll need to first install the XScreensaver package. To do this, type sudo apt-get install xscreensaver into a Terminal window.

Читайте также:  Windows media player что за формат

Now open the XScreensaver control panel. It doesn’t show up in the System Settings, but if you type “screensaver” in the Unity Dash, you’ll see it.

The first time you do this, you may find that you receive a warning window, informing you that a screensaver daemon is already running.

Go ahead and click to turn off the Gnome-Screensaver daemon (which is really only the screen dimming feature). Now turn on the XScreensaver daemon.

You should now see the main XScreensaver controls.

Now (finally!), go ahead and change the Mode: setting to

Founder of Help Desk Geek and managing editor. He began blogging in 2007 and quit his job in 2010 to blog full-time. He has over 15 years of industry experience in IT and holds several technical certifications. Read Aseem’s Full Bio

Источник

How to turn ON/OFF screen monitor using shell script and ‘xrandr’ linux command?

I am trying to turn on and off screen monitor in Ubuntu14.04 using key bindings.
I tried the following shell script:

1) This above script is working fine in Ubuntu 10.04, but not working properly in Ubuntu 14.04.

2) I bind this script on Ctrl + Alt + M key.

3) When I press this key binding it will off the monitor but again I pressed this key binding it will not start screen monitor.

4) I try to run this command

but nothing happens.

5) I also tried this command

but if any key is pressed it will start the screen monitor.

So what should I do to turn the screen monitor on or off using a shell script?

1 Answer 1

Often times a laptop will have it’s own screen key binding that turns on and off the display. If your laptop has no such key, try searching for programs other than xrandr that will do what you want. Ubuntu’s default screensaver can assign a key that will automatically turn off and lock the screen.

  1. Navigate System Settings > Keyboard > Shortcuts > System.
  2. Click the + , name your custom shortcut anything you want, and put as the command gnome-screensaver-command -la .
  3. Click Apply , then assign the shortcut you want to add.

Источник

Оцените статью