Cant log in from external monitor on laptop with broken screen.

Hello. I am installing Kali Linux on a laptop with no monitor. The installation goes fine through the external monitor and I can see the GRUB menu on boot, but once it comes time to log in it acts like my non existant laptop screen is my main monitor to type my login info on while my external is just grey background. Moving the mouse cursor it will appear from the left hand side of the screen and I can enter the ctrl alt f3 terminal and log into root. Search engine results seemed 'xrandr' in the terminal could help me select my external monitor as the main one through terminal or boot commands. But when I type it in it says "Cannot show display" I checked the xrandr --help and tried other commands to the same effect. Wont even list displays with xrandr -q. Also built in laptop FN display commands only make the screen flash for a millisecond. Also checked BIOS for any video settings that I could change, there is nothing. I also tried logging in blind by typing passphrase, return key, also tried return, passphrase, return, no effect. I know if I can log in blind I can right click the background and select the graphics options from the shell to mirror the displays. If anyone can help me with a solution or you need any additional information please respond I would greatly appreciate it.

Let me understand better...

You are connecting your laptop to your external monitor using what port exactly?

When you turn off the laptop and reboot it attached to an external monitor what do you see. exactly?

I am using VGA port from a laptop. When the machine is turned on, the external monitor displays the GRUB boot menu listing my operating systems to boot (kali + kali advanced + windows 7). I select kali, my monitor shows some pages of code of the OS starting, screen goes black for a few seconds, then a grey background appears with nothing else. If I leave the computer for a couple minutes and let the monitor sleep, the blue kali background will be on my screen upon awaking, which I can move out of the way with the mouse.

HI, debpleb
Try to start switching to a virtual console and see the logs.

--- Post updated at 19:50 ---

In any case, I will give the procedure
press Alt+Ctrl+F1
Log in and
sudo journalctl -p err
First of all, check the ability to switch to the console

1 Like

The command brought up something along the lines of

-- log begins (boot time?) log ends (current time) --
 -- no entries --

and so

journalctl -b -1 -p err

--- Post updated at 12:33 ---

In order not to read too much in your case, it probably will do:
journalctl -b -1 -p emerg or journalctl -b -1 -p 0 which is equivalent to
Error level code from 0 to 7

1 Like

This sounds like your laptop is treating the external monitor as a secondary display and the (non-existing?) internal display as first. Perhaps the laptop has an internal graphics adapter and it treats the internal display as first, the external as second.

Usually laptops have some "function key" to switch that behavior. If you could tell us the exact making of your laptop somebody might even know how to do it.

I hope this helps.

bakunin

2 Likes

You can use the file ~/.xinitrc

#!/bin/sh
xrandr --output VGA1 --mode 800x600 #example

or

xrandr --output VGA1 --primary

--- Post updated at 14:03 ---

It is also possible that your video output is called VGA-0

Can you ssh to kali 'broken screen' with cable connected and DHCP available in the network ?
From the terminal, check out /var/log/Xorg.0.log (or similar) to see if your display is detected and X running.
If you do not know the IP address, a simple nmap -sn n.n.n.0/24 should provide live hosts in simple home network environment.

You can also execute other commands, and provide additional details, such as lspci , lshw , lsmod .

Depending on your hardware, you might need a non-free firmware package if you have video issues.
For instance, you say 'you can move your mouse after some time and see it', which probably means X server is running.

What is the model of your laptop ?

Hope the helps
Regards
Peasant.

1 Like

I do have the laptop function keys, but when I press the FN + F5 it just makes the screen flash for a split second without switching it.

Also I was able to connect to the internet during the install, I'll try to learn more about live hosts and see if it can assist me. Laptop is an Acer aspire 7736z - 4088.

Thanks everyone for your responses, I will try the advice mentioned here and report later today.

journalctl -b -1 -p emerg 
journalctl -b -1 -p 0

Both of these brought up "Specifying boot ID or boot offset has no effect, no persistant journal was found"

"You can use the file

~/.xinitrc"

in my etc/X11 directory it has some Xsession sort of stuff, I tried ./Xsession but it just says "Terminated". There
was no /xinit I could find. I did see initrd.img in / but it wont let me open it.

Any and all xrandr commands always show "Cant show display"

"check out

/var/log/Xorg.0.log

(or similar) to see if your display is detected and X running."

I could not find this file, and everything in this directory tells me "permission denied" when trying to open it,
like most things.

lspci, lshw, and lsmod came up with whats in the attachments

EDIT not sure if they were uploaded here are online links just incase

lspci - imgbb.com
lsmod - imgbb.com
lspci continued - imgbb.com

The Acers have a "Fn" key modifier but the various models are not consistent about which key goes to what: some models have

- Fn-key + F<n>-key = "normal" F-key
- F<n>-key = special laptop functions like "switch screen", "higher/lower brightness", etc.

and on some models this is reversed. If i remember correctly i needed to adjust that in the BIOS of my own Acer E5-774G so that the F<n>-keys are working normally without having to press <Fn> each time. Try " F5 " alone (without the <Fn> key) as this may switch the screen.

I hope this helps.

bakunin

PS: you may need this link with a manual for your laptop

Would anyone here be able to tell me how I could log in blind using just the keyboard without seeing? I tried 'passphrase' then return, return 'passphrase' return, 'passphrase' tab return. If I could log in this way I could just right click the desktop for shell menu graphic options to mirror the displays. Or maybe a way to have a boot command that auto logs me in?

Depending on the desktop you use (sorry, i don't know Kali Linux) you can automatically login with a certain user. You will have to have a running desktop for that to configure, though.

I think for a test or just to get unstuck for the moment it is possible to set the password to "" so that you only have to press <ENTER>. It may be that the user itself is not allowed to set NULL passwords but root will be able to do that for the user:

passwd -d [username]

Notice, though, that this user cannot use the administration features of the desktop. Most desktops have a "built-in su " so to say - i.e. you can start some graphical package manager and install packages (which only root is allowed to do) but you have to identify yourself to the tool with your password. Such things are not possible wih a passwordless user.

I hope this helps.

bakunin