Jump to content

Photo

'xrandr --scale' script appears to crash desktop - can anyone duplicate this?

xrandr scale crash

Best Answer DOOMguy , 22 December 2017 - 04:01 PM

ok, looks like you have enough to go on, and it's interesting that you are asking people if they can crash their desktop. It is like approaching some guy Hey can you drive your car into that wall? Here's a helmet, but I don't know if you need it

 

Most people here would rather not play kamikaze -- they are wary of any after effects e.g. icons in shelves damaged, no icons

 

but run xrandr -q so you can pick a different resolution, and you can omit 'scale' so we get plain vanilla display as a result. Not the whole window; that's fine. We're pushing the Atom to do it, no extras needed. Can it be done without crashing.

 

I think this is called trial-and-error by lab scientists.

Go to the full post


  • Please log in to reply
7 replies to this topic

#1 penguinator

penguinator

    Member

  • Members
  • 330 posts
  • LocationFunchal

Posted 21 December 2017 - 08:17 PM

This is a continuation of this post, but the Topic Title has changed so completely, that I thought starting a new thread would make the subject of this problem clearer for others who may be trying to solve the same problem.

 

I transferred the resolution-changing scripts from the previous version to Bodhi 4 and ran them. There is a problem with the script that uses the 'scale' parameter for xrandr.

 

What happened:  something crashed and I don't think it was the operating system, because a reboot was not required.  As soon as the script was run, the screen went black, an arrow cursor appeared for a half-second, and I then was taken back to the log-in screen.  All that was running under the previous session was gone.  This was repeatable.

 

This script has been working for about nine years, ever since I replaced the original Xandros OS with a succession of Ubuntu variants.  It is still working perfectly on the previous Bodhi version, with Enlightenment 17.

 

Here is the entire script:

#!/bin/bash
RES=`xrandr | grep LVDS1 | awk '{print $3}' | awk -F "+" '{print $1}'`
if [ $RES = 1200x720 ]; then
    xrandr --output LVDS1 --panning 1094x656 --mode 800x480 --scale 1.367x1.367
else
    xrandr --output LVDS1 --panning 1200x720 --mode 800x480 --scale 1.5x1.5
fi
exit

As a test to see what was doing it, I copied-and-pasted the lines beginning with 'xrandr', one at a time, into the terminal, and Moksha crashed both times.  The current problem appears to be here, and not in the resolution-sensing code.

? Has there been a change in xrandr, that requires modifying my script?  Note, the xrandr version numbers have changed.  Or, is it something else?

 

This is happening with the original L701 (refer to system info in post's signature) -- I'm leaving the older Bodhi version on the 701SD, where the scripts still work, until I get this straightened out.

 

xrandr program version 1.5.0, RandR version 1.5 (on L701 with Bodhi 4.4 and Moksha)  -- crashes

xrandr program version 1.4.1, RandR version 1.4 (on L701SD with Bodhi version as in my signature) -- works normally

 

 


Bodhi v3.0.0 / stable - 32 bit, Legacy
ASUS eeePC 4G/701-L, Atheros wireless module | ASUS eeePC 701SD, Realtech wireless module

701L, 701SD - Celeron-M 900Mhz
 




A big thank you to everyone who contributes to Bodhi Linux


#2 DOOMguy

DOOMguy

    Member

  • Members
  • 259 posts

Posted 21 December 2017 - 09:39 PM

Let's try something else then (the result may not have anything to do with xrandr, and let us try these things regardless of xrandr moving the goalposts)

Take out --scale
Put in a higher scale factor (do not jump too large, try small increments)
Use the GUI tool with the slider for the scale factor.


I am on a MBP at the moment, but even on my laptop at home I do not have the HW that you have. I am not on Moksha but I recall somewhere where the scaling is set by a slider, instead of typing a number.

There are two ways to find that sweet spot. One is described in step 2. If you dual boot, use the slider in windows to pick 'smart numbers' in guessing. (How were you able to pick 1.367, 1.5 -- you ought to be able to figure out the next magic number)

Your IF - ELSE script could be useful in another way. The IF is for setting up 1200x720; what resolution does the ELSE set in your script? Rewrite so that there are three cases, not just these two. Set it up without resorting to scale--that is, make the pan-and-scan an option, instead of a must-have. You may be reaching the edge of the Intel Atom's graphics capabilities.
 


Unsolicited advice for learning linux, that won't cost you anything


#3 penguinator

penguinator

    Member

  • Members
  • 330 posts
  • LocationFunchal

Posted 21 December 2017 - 11:51 PM

...
Take out --scale
Put in a higher scale factor (do not jump too large, try small increments)
Use the GUI tool with the slider for the scale factor.
...
 

Thanks for taking the time to help with my problem!

 

I don't follow -- if I 'take out --scale' I'm certain it will work, but only in the pan-and-scan mode, not by increasing virtual display resolution.  This script is one of two, with the first one for toggling through two modes of pan-and-scan.  That one works just fine, just as it did, in all previous desktop environments. So I didn't bother to list it. 

 

The one listed in this thread is for toggling through two levels of virtual resolution.  These scripts see most of their use on displaying web sites, because not all web sites reformat themselves properly in response to the resolution of the display being used to view them. So, when something doesn't look right, I just start 'toggling' the display modes, and stop when it does look right. 

 

Having said that, I appreciate your calling that module to my attention because I didn't even know it existed!  I suspected there might be something new and helpful in Moksha, but I didn't pursue that after Jeff told me that I was best-off by sticking with the scripts, controlled by short-cut keys.  And, Jeff knows Moksha's capabilities better than anyone else. 

 

Even so, I am now curious about this module and will 'play' with the settings to see what effect it has.  As a first impression, I am doubtful whether it's compatible with my wanting to 'hop back-and-forth' between resolutions while watching for the best result.  But, I haven't used that Scale module yet, so I accept that I may be surprised and find it useful -- in ways I can't anticipate. 

 

Your suggestion about rewriting the script is good.  At the time (9 years ago!) I tried for one script that would toggle through both two levels of pan-and-scan and then through two levels of virtual resolution scaling, and then back to normal.  Going through so many display modes without labels proved confusing, so I decided it was better to leave it at two scripts, each with a distinct purpose.  So, for the last nine years, it's been set-up like so: <Ctrl><~> toggles through pan-and-scan and back to normal, and <Ctrl><f1> toggles through virtual resolution. 

 

This gives you and anyone else who would like to help an idea of the behavior I'd like to continue seeing.  And thanks for the heads-up on that Scaling module.  I'll look at it first thing tomorrow morning!


Bodhi v3.0.0 / stable - 32 bit, Legacy
ASUS eeePC 4G/701-L, Atheros wireless module | ASUS eeePC 701SD, Realtech wireless module

701L, 701SD - Celeron-M 900Mhz
 


#4 penguinator

penguinator

    Member

  • Members
  • 330 posts
  • LocationFunchal

Posted 22 December 2017 - 01:44 AM

...

I am not on Moksha but I recall somewhere where the scaling is set by a slider, instead of typing a number.
...
 

I will need some help on finding this slider ... because I am experimenting with a 'slider' in a Scaling module ... and the only thing I see changing is the size of the system fonts.

 

As noted above, I need to change the scaling of the browser display ... and from this location, in the Scaling module ... I see no change in the browser.  I am using Firefox, if that makes any difference. 

 

I think I'm now back to asking for help to get xrandr to work in scaling mode, without crashing the desktop??


Bodhi v3.0.0 / stable - 32 bit, Legacy
ASUS eeePC 4G/701-L, Atheros wireless module | ASUS eeePC 701SD, Realtech wireless module

701L, 701SD - Celeron-M 900Mhz
 


#5 penguinator

penguinator

    Member

  • Members
  • 330 posts
  • LocationFunchal

Posted 22 December 2017 - 01:05 PM

The Desktop also crashes with a very basic xrandr command, typed into terminal, as described on this page:

 

Open a Terminal and at the prompt type:
xrandr --output LVDS1 --mode 800x480 --scale 1.5x1.5
Substitute the "-- mode 800x480" for your native resolution if using on other Eeepc's (901 etc)...

 

 

This would make it easy to troubleshoot if Bodhi 4.4 with Moksha is running on other hardware, assuming an EeePC L701 is not available.

 

First, run the command xrandr without any parameters -- and based upon what you see, make the appropriate substitutions for the output and mode parameters. 

? Can anyone duplicate the desktop crash, if that's what it is?


Bodhi v3.0.0 / stable - 32 bit, Legacy
ASUS eeePC 4G/701-L, Atheros wireless module | ASUS eeePC 701SD, Realtech wireless module

701L, 701SD - Celeron-M 900Mhz
 


#6 DOOMguy

DOOMguy

    Member

  • Members
  • 259 posts

Posted 22 December 2017 - 04:01 PM   Best Answer

ok, looks like you have enough to go on, and it's interesting that you are asking people if they can crash their desktop. It is like approaching some guy Hey can you drive your car into that wall? Here's a helmet, but I don't know if you need it

 

Most people here would rather not play kamikaze -- they are wary of any after effects e.g. icons in shelves damaged, no icons

 

but run xrandr -q so you can pick a different resolution, and you can omit 'scale' so we get plain vanilla display as a result. Not the whole window; that's fine. We're pushing the Atom to do it, no extras needed. Can it be done without crashing.

 

I think this is called trial-and-error by lab scientists.


Unsolicited advice for learning linux, that won't cost you anything


#7 penguinator

penguinator

    Member

  • Members
  • 330 posts
  • LocationFunchal

Posted 23 December 2017 - 01:01 AM

... run xrandr -q so you can pick a different resolution, and you can omit 'scale' so we get plain vanilla display as a result. ...

Thanks again for helping ... but I don't see how any of the modes I see there would increase resolution.  I didn't know that the -q parameter would give results identical to running the command xrandr -- with no parameters. 

 

Anyone else?

 

If no one's able to duplicate the problem, after another day or so, I'll have to assume the 'aberrant behavior' is limited to my installation, reinstall moksha and try xrandr again.


Bodhi v3.0.0 / stable - 32 bit, Legacy
ASUS eeePC 4G/701-L, Atheros wireless module | ASUS eeePC 701SD, Realtech wireless module

701L, 701SD - Celeron-M 900Mhz
 


#8 penguinator

penguinator

    Member

  • Members
  • 330 posts
  • LocationFunchal

Posted 24 December 2017 - 05:45 PM

I'll close this thread now, and give DOOMguy credit for the best of the solutions received so far.  It's quite possible that what I saw as a problem may respond to reinstalling moksha.  Thanks!


Bodhi v3.0.0 / stable - 32 bit, Legacy
ASUS eeePC 4G/701-L, Atheros wireless module | ASUS eeePC 701SD, Realtech wireless module

701L, 701SD - Celeron-M 900Mhz
 






Also tagged with one or more of these keywords: xrandr, scale, crash

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users