xrdp is not connecting to SLES11 SP4 - linux

I have a SLES11 SP4 machine available with me. I have installed xrdp using zypper.
The command I used to install was zypper in xrdp and followed on-console messages.
xrdp installed successfully. But when I tried to connect from Windows 7 machine it said the machine is not up. I tried to start xrdp by typing command xrdp, it started and said xrdp started and gave a pid. Now connecting through windows was leading to login. I entered the credentials and it went into forever connecting mode.
Tried stopping xrdp by xrdp -kill and restarting again. But doesn't work.

I did a fair amount of research regarding this issue. I could find that just executing command xrdp doesn't work. The xrdp should be started with the system's own service startup mechanism.
For ex.
in SLES11 machines, use command /etc/init.d/xrdp start
in SLES12 machines, use command systemctl start xrdp
Similarly use the native system service management to startup and shutdown xrdp. Since my machine is SLES11 I used the above command and it worked.
Before executing that, we have to kill all the xrdp processes, restart the machine and start the xrdp using above commands.

Related

how can i get systemd files to work on wls ubuntu 20.04

I created a service file named pointless.service but when I run
sudo systemctl start pointless it returned
System has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down
when I also tried sudo service pointless start
but it returned pointless: unrecognized service.
i am using wsl ubuntu 20.04
the above commands work for installed software like Nginx, Redis e.t.c. but it isn't working for any of my files

XRDP doesnt connect to Azure VM suddenly

The RDP doesnt connect to the Azure Linux VM suddenly, the error is:
Password failed, error- problem connecting.
This is the first time its happening. And I tried restarting the VM, Resetting the password and also removing the credentials and adding again to the rdp. Please support on this.
I have encountered exactly the same issue on ubuntu 14.06 running on AWS today.
I checked the /var/log/apt/history.log and found out that the system updated the xrdp package automatically xrdp:amd64 (0.6.1-2, 0.6.1-2ubuntu0.1)
I downgraded the package and it now works again.
sudo apt-get install xrdp=0.6.1-2
Then, I decided to exclude xrdp from automatically being updated.
sudo apt-mark hold xrdp
xrdp set on hold.

Teamviewer linux without permanently running daemon

Teamviewer Linux has the annoying property of installing a permanently running daemon. This not only consumes resources but also presents a security risk. You can disable the daemon startup, however then the teamviewer client does not work anymore.
The best way is to enable the daemon before running the teamviewer script and disable it again after the teamviewer client has closed.
The following shell script handles things automatically:
#!/bin/sh
echo starting teamviewer daemon
sudo teamviewer --daemon enable
teamviewer &
wait $!
echo teamviewer finished
sudo teamviewer --daemon disable
echo stopped and disabled teamviewer daemon
On ubuntu 18.04, here how I solve this
Stop autostart demon
$sudo systemctl disabled teamviewerd.service
create script /opt/tm.sh
#!/bin/bash
pkexec --user root systemctl start teamviewerd.service;
/opt/teamviewer/tv_bin/script/teamviewer;
pkexec --user root systemctl stop teamviewerd.service;
Set bash script executable
chmod u+x /top/tm.sh
Update de /usr/share/applications/com.teamviewer.TeamViewer.desktop
Exec=/opt/tm.sh
It work perfecly for my needs. I only need to connect to other computer never to mine, so root deamon always running is not needed.
Let's see how it live with update from ppa of Teamviewer
The solution Fedora 30+ is:
# systemctl disable teamviewerd.service
# systemctl stop teamviewerd.service
But don't forget to start the service again in order to get a TeamViewer ID.
# systemctl start teamviewerd.service
The tar package allows to run the TV client without installation and without root privileges.

Ubuntu Desktop not visible on Azure xrdp

I am trying to set up remote Ubuntu desktop on Azure free tire. I have followed all the steps mentioned in here and Azure Documentation. I have setup instance with resources manager. Setup the rdp. Install xrdp via ssh. Install Ubuntu desktop as well.
Installed -- Ubuntu Server 16.04 LTS
Also installed xfce as mentioned in Azure Documentation
In-spite of installing everything properly I see dotted screen when I connected remotely. What am I doing wrong ?
Using xfce if you are using Ubuntu version later than Ubuntu 12.04LTS
We can follow those steps to install xrdp:
sudo -i
1.Install XRDP Package from Ubuntu Repository
apt-get install xrdp
2.Installing the xfce4 Desktop environment
apt-get update
apt-get install xfce4
3.Configure xrdp to use xfce desktop environment
echo xfce4-session >~/.xsession
4.Restart xrdp service
service xrdp restart
5.Test your xrdp connection:
We can use mstsc to test xrdp connection.
Note:
If you use this command apt-get install xfce4 get this error message:
W: mdadm: /etc/mdadm/mdadm.conf defines no arrays.
Please add ARRAY <ignore> devices=/dev/sda to /etc/mdadm/mdadm.conf, like this:
root#ubuntu:~# cat /etc/mdadm/mdadm.conf
# mdadm.conf
#
# Please refer to mdadm.conf(5) for information about this file.
#
ARRAY <ignore> devices=/dev/sda
# by default (built-in), scan all partitions (/proc/partitions) and all
# containers for MD superblocks. alternatively, specify devices to scan, using
# wildcards if desired.
More information about xrdp on azure vm, please refer to this link.

Accessing Azure Virtual Machine (Ubuntu 14.04LTS) using xRDP

Yesterday, I setup a new Ubuntu Box with Password (Classic VM) from my Azure Dashboard ( I am using classing Azure dashboard).
I am able to login using Putty (it means credentials are working).
To access this machine remotely (already setup CDN for Remote Desktop), I followed steps mentioned (https://azure.microsoft.com/en-in/documentation/articles/virtual-machines-linux-classic-remote-desktop/) to setup xRDP - please note that I am trying to access this box from Windows8.1 machine.
All seems to be successfully installed. Received errors, when tried to remote into Ubuntu VM:
Fire Run -> mstsc.exe (entered hostname/IP and credentials)
Entered credentials
Process threw few error messages
Its not working even after trying all troubleshooting steps:https://azure.microsoft.com/en-in/documentation/articles/virtual-machines-linux-troubleshoot-ssh-connection/
Installing xfce4 with
sudo apt-get install xfce4
have always worked fine for me!
I follwed this guide when I got started:
http://c-nergy.be/blog/?p=5305
You can also check out this thread for hints:
https://askubuntu.com/questions/449785/ubuntu-14-04-xrdp-grey
I repeat these step(s) once again and its working now:
sudo apt-get update
sudo apt-get install ubuntu-desktop
sudo apt-get install xrdp
sudo systemctl start xrdp
sudo systemctl enable xrdp
sudo apt-get install xfce4
Now do RDP (Run mstsc.exe) - enter hostname and passowrd

Resources