Showing posts with label nanopi t4. Show all posts
Showing posts with label nanopi t4. Show all posts

Thursday, August 19, 2021

install xrdp for remote desktop on friendlyarm ubuntu version, focal 20.04.

Must translate thru google translate.  Translated version copied and pasted here.

XRDP with xorg doesn't work, probably due to missing hardware to frame buffer.  Seems to rig to use vnc remote desktop method to  remote the desktop.

Installed xfce4 for window manager

<run following thru google translate for updated info>
snapshot copied and saved 8/19/2021

https://wiki.friendlyarm.com/wiki/index.php/How_to_setup_XRDP_server_on_NanoPC-T4


How to setup XRDP server on NanoPC-T4

View Chinese

1 Step1: Install XRDP remote desktop

Enter the following command to install:

sudo apt install  -y tigervnc-standalone-server xrdp
 sudo  sed  -e  's/^new_cursors=true/new_cursors=false/g'  -i  / etc / xrdp / xrdp.ini

2 Step2: Edit /etc/xrdp/startwm.sh

Edit /etc/xrdp/startwm.sh:

sudo  vim  / etc / xrdp / startwm.sh

Comment out the last two lines in the file (comment method: add # sign at the beginning of the line), as shown below:

# test -x /etc/X11/Xsession && exec /etc/X11/Xsession 
# exec /bin/sh /etc/X11/Xsession

Then add the following at the end of the file:

lxsession -s LXDE -e LXDE

3 Step3: Edit /etc/xrdp/xrdp.ini

Edit /etc/xrdp/xrdp.ini

sudo  vim  / etc / xrdp / xrdp.ini

Scroll to the address of "; Session types", delete all other session types, only [Xvnc] is left:

;
; Session types
;
; Some session types such as Xorg, X11rdp and Xvnc start a display server.
; Startup command-line parameters for the display server are configured
; in sesman.ini. See and configure also sesman.ini.
 [ Xvnc ] 
name =Xvnc
 lib =libvnc.so
 username =ask
 password =ask
 ip =127.0.0.1
 port =- 1 
#xserverbpp=24 
#delay_ms=2000

4 Step4: Disable light-locker

Since light-locker will not work properly in the XRDP environment, we need to disable it in the XRDP environment. In order not to affect the real environment, here we use a packaging script to solve the problem. First, rename the original file:

the sudo  CP  / usr / bin / Light-Locker / usr / bin / Light-locker.orig
 the sudo  RM  / usr / bin / Light-Locker

Create another script to call it, and use the editor to create a file /usr/bin/light-locker with the following content:

#!/bin/sh
 
# The light-locker uses XDG_SESSION_PATH provided by lightdm. 
if  [  !  -Z  " \$ {XDG_SESSION_PATH}"  ] ; then 
  / usr / bin / light-locker.orig
 else 
  # Disable light-locker in XRDP. 
  true 
fi 
EOF

Give the script executable permissions:

sudo  chmod  755  / usr / bin / light-locker

5 Step5: Start xrdp service

sudo systemctl enable xrdp
 sudo systemctl restart xrdp

6 Step6: Test the remote desktop connection

Use the Microsoft Remote Desktop client to create a new connection, the address is the IP address of the development board, and the user name and password are pi. In order to get a better experience, the resolution is recommended to be set to 1280x800, and the color depth is 24 bits. The settings are as shown in the figure below. Shown:

  • Xrdp-ip.png
  •  
  • Xrdp-settings.png

After the connection is successful, as shown in the figure below:
Win-xrdp-friendlydesktop.png


--30--

Wednesday, June 20, 2018

friendlyarm nanopi t4 with rockchip 3399


Notes about setting up Lubuntu bits on the t4 board

login is pi, default pi

http://wiki.friendlyarm.com/wiki/index.php/NanoPC-T4#Connect_NVME_SSD_High_Speed_Hard_Disk_to_T4

Connect NVME SSD High Speed Hard Disk to T4

Connect a NVME SSD hard disk to NanoPC-T4's M.2 interface, initialize and automatically mount the SSD by running the following commands. Before proceed turn off your T4 and connect an SSD to your T4. Power on your T4 and open a command line utility(go to top left of the GUI and enter System Tools -> LXTerminal) or SSH to your T4.

We suggest you switch to "root" by running the following command:
su -
The password for "root" is "fa".

Detection of SSD

root@FriendlyELEC:~# cat /proc/partitions 
major minor  #blocks  name
   1        0       4096 ram0
 259        0  125034840 nvme0n1
If there is a nvme0n1 device node it means an SSD is recognized by T4.

Partition of SSD

To mount an SSD under Linux we re-partition it as one section by running the following command:
(echo o; echo n; echo p; echo 1; echo ""; echo ""; echo w; echo q) | fdisk /dev/nvme0n1
If you want to re-partition it to multiple sections you can run "fdisk /dev/nvme0n1". For more detail about this command refer to the fdisk's manual.

Format Section to EXT4

After an SSD is successfully partitioned you can check its sections by running "cat /proc/partitions". The image provided treats a PCIe nvme device's sections as an eMMC's sections you will find that an SSD has some small sections.

We can check the "blocks" column and the biggest section is available for users. The /dev/nvme0n1p7 section is used to store data:
root@FriendlyELEC:~# cat /proc/partitions 
major minor  #blocks  name
   1        0       4096 ram0
 259        0  125034840 nvme0n1
 259        1       4096 nvme0n1p1
 259        2       4096 nvme0n1p2
 259        3       4096 nvme0n1p3
 259        4      12288 nvme0n1p4
 259        5      32768 nvme0n1p5
 259        6      32768 nvme0n1p6
 259        7  124932440 nvme0n1p7

The following command formats a section to ext4:
mkfs.ext4 /dev/nvme0n1p7

Auto Mount SSD on System Startup

Before we mount an SSD's section you need to know its Block ID. You can check it by running "blkid":
blkid /dev/nvme0n1p7
/dev/nvme0n1p7: UUID="13fb682e-ef40-4c71-b98b-3d17403e1205" TYPE=“ext4"
Add a "Block ID" to "/etc/fstab" and here is what it looks like
UUID=<Block ID> /media/nvme ext4 defaults 0 0
You need to replace <Block ID> with the UUID obtained by running "blkid". To mount the SSD in our example we made the "/etc/fstab" file as follows:
UUID=13fb682e-ef40-4c71-b98b-3d17403e1205 /media/nvme ext4 defaults 0 0
We want to mount an SSD to "/media/nvme" but this directory doesn't exist. Therefore we create it and change its access right by running the following commands:
mkdir /media/nvme
chmod 777 /media/nvme
Run "mount" to check if the SSD is mounted successfully:
mount /media/nvme
You can reboot your T4 to check if your SSD will be automatically mounted:
poweroff

-30-