Re: can I issue commands to X session from a text vt?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 22 Jul 2025 21:28:20 +1000 fedora@xxxxxxxxxxxxxx wrote:
> On 22/7/25 18:16, Barry Scott wrote:
>> Try like this:
>> 
>> XAUTHORITY=/run/user/1000/xauth_icQwML DISPLAY=:0.0 xterm  
 
> I do not have any (my uid is 500)
> 	/run/user/500/xauth_*
 
> 'locate' knows of none either.

locate does not browse /run by default (see /etc/updatedb.conf) and
have to be run since Xorg starts to give a valid result.

You can usually find what xauthority file is used by looking at the -auth
option given to the Xorg process. Ex: ps auxwww | grep Xorg

This depends on how Xorg is launched: gdm lightdm startx ...

Normally the xauthority record is added to you ~/.Xauthority file.
This seems the case for you.

> What does work is running (from tty2)
> 	xterm -display :0
> then switching to tty1 (blank screen)
> then typing (blind) the xrandr command. For ease I created ~/xx.sh
> to do the xrandr and it works. 

> It seems that unless I have tty1(Xorg) active the xrandr does not do
> it, but running the same command while on tty1 does work.

Using chvt to make tty1 active and then execute the xrandr may
work. No need to start an xterm.

Try thus this (from tty2):

  chvt 1; sleep 1; xrandr --display :0 --output HDMI1 --mode 3840x2160

-- 
francis
-- 
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/users@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux