Closed Root-voidX closed 6 years ago
@Root-voidX you are welcome. Thank you for using TermuxArch :bow_and_arrow: and sharing interesting questions.
installed LXDE but when I use XServer
How to use Xorg in TermuxArch? #27 should have the answer that you are seeking. Share screenshots and instructions of your success thus far.
installed LXDE
Sharing will help us do more on device with Termux today. Many of our questions are solved, but the information has not been disseminated to everyone. Fortunately Termux has an FAQ, and this has freed up developer's time resources. Termux Packages is a good example today. It's easy to create packages, but how is not that easy to answer except for, "Documention is forthcoming, please contribute."
Email : termux+subscribe@groups.io Github : https://github.com/termux/ Gitter : https://gitter.im/termux/termux Termux Community : https://plus.google.com/communities/101692629528551299417 Try Arch Linux https://github.com/archlinuxarm too. When you find answers, share them here for us all.
For issue with the fonts, some things are missing from the lxde-font package. The fix is installing ttf-dejavu
... [20:50 home ]$ pacman -S ttf-dejavu resolving dependencies... looking for conflicting packages...
Packages (4) xorg-fonts-encodings-1.0.4-4 xorg-mkfontdir-1.0.7-8 xorg-mkfontscale-1.1.3-1 ttf-dejavu-2.37-2
Total Download Size: 2.93 MiB Total Installed Size: 10.56 MiB
...
I still haven't figured out how to add AUR, but I got octave working easily.
I dont know if P-Root is working on 8.0 yet. I'll keep you guys/girls posted.
@Root-voidX this is great news that Linux is running in your device. Linux on the go; Incredible. Can you share a brief tutorial how you got X up and running in Arch Linux in Termux PRoot. Add a screenshot or two if possible. The more guides there are, the easier it will be for new users, even really brief ones. Here is a discussion about building packages in Arch Linux, Succesfully Modified Stock 'makepkg'... #38.
@Root-voidX here is an IRC https://wiki.archlinux.org/index.php/IRC_channel link that will be useful for asking some of these questions upstream.
This https://github.com/sdrausty/TermuxArch/commit/f16c27d4336ff6e38e1338e7846adc8843b9c0fc commit adds Arch Linux IRC channel upstream contact information to the TermuxArch motd and logout.
Hey @sdrausty thanks for the links. Its been a bit busy on my end, Hopefully this weekend I can spend some time to work on getting some things on arch done after i install it on my s9+.
In terms of getting X up and running, i followed this step:
pacman -S xorg-server
pacman -S lxde
*note that since there are multiple LXDE packages that pacman finds, I installed all (which is the default option)
then since lxde-font might not work, to fix install ttf-dejavu by typing:
pacman -S ttf-dejavu
After that I launch XSDL first and then switch back to termux. Inside arch I type in:
DISPLAY=:0 startlxde
and once I press enter I switch back to XSDL and it should start LXDE.
Note: It is possible to get audio as well, to do so install pulseaudio and type in the local address shown in XSDL
@sdrausty
I tried installing termux-arch following option 2. Doesn't matter how many times I clear cache. Install goes okay but proot exits since It can't find /env.
This is for android 8 on s9+
@Root-voidX is env
where startarch
points to in Android 8? Can you post complete output for Android 8 including setupTermuxArch.sh sysinfo
?
Use setupTermuxArch.sh refresh
to refresh the installation and the TermuxArch files. This will run the script from the point after downloading and unpacking the system image, and editing the Arch Linux configuration files by only updating Arch Linux and refreshing all the TermuxArch files to the newest version.
Thank you for sharing instructions about startlxde! Have you tried any of the other desktop environments?
@sdrausty
No I haven't but running xfce or twim should be possible following the same steps.
In terms of updates, this is the error I get running arch after installing it:
$ startarch
proot error: '/bin/env' not found (root = /data/data/com.termux/files/home/arch, cwd = /data/data/com.termux/files/home, $PATH=(null))
fatal error: see `proot --help`.
$
@Root-voidX this https://github.com/sdrausty/TermuxArch/commit/0cfde87a3f5a2bddb7fca7dbfa243547be890327 commit should resolve the Android 8 error. Can you confirm whether it does?
I use android oreo
I do all steps and it show a empty file in nano mirrorlist and dont proot to arch with this error
proot error: '/usr/bin/env' not found (root = /data/data/com.termux/files/home/arch, cwd = /data/data/com.termux/files/home, $PATH=(null))
fatal error: see proot --help
.
Yes nano shows an empty file as well when I did install it before. @sdrausty should i manually replace the changes in the commit, or does the git clone or wget copy the commit changes ?
I'll try tonight =)
@aarmn @Root-voidX
Topic 1)
Where is env
? Does editing the exec proot statement in startarch
help in any way for Android 8? To ask upstream about why it works on >8, but not on <=8 tap here.
Topic 2)
empty file
setupTermuxArch.sh sysinfo
for these devices is requested; Can this be reproduced on Android >8?
The output @sdrausty is as followed for sysinfo:
bash setupTermuxArch.sh sysinfo
๐ > ๐ setupTermuxArch v1.5 will create a system information file. Ensure background data is not restricted. Run bash setupTermuxArch.sh help for additional information. Check the wireless connection if you do not see one o'clock ๐ below. Checking prerequisitesโฆ
๐ > ๐ง Prerequisites: OK Downloading TermuxArchโฆ
setupTermuxArc 100% 153 --.-KB/s in 0s
setupTermuxArc 100% 18.77K --.-KB/s in 0.009s
๐ > ๐ TermuxArch download: OK
๐ > ๐ TermuxArch v1.5 integrity: OK
Begin setupTermuxArch debug information.
`termux-info` results:
Updatable packages:
binutils/stable 2.30-2 aarch64 [upgradable from: 2.30-1]
busybox/stable 1.28.2 aarch64 [upgradable from: 1.27.2-1]
git/stable 2.17.0 aarch64 [upgradable from: 2.16.2]
less/stable 530 aarch64 [upgradable from: 487]
libsqlite/stable 3.23.0 aarch64 [upgradable from: 3.22.0]
openssh/stable 7.7p1 aarch64 [upgradable from: 7.6p1]
openssl/stable 1.0.2o aarch64 [upgradable from: 1.0.2n]
python/stable 3.6.5-1 aarch64 [upgradable from: 3.6.4-1]
sed/stable 4.5 aarch64 [upgradable from: 4.4-1]
System information:
Linux localhost 4.9.65-13087505 #1 SMP PREEMPT Sun Feb 25 18:48:40 KST 2018 aarch64 Android
Termux-packages arch:
aarch64
Android version:
8.0.0
Device manufacturer:
samsung
Device model:
SM-G965W
Disk report 34518344 on /data Thu Apr 5 16:36:38 EDT 2018
BASH_VERSINFO[0] = 4
BASH_VERSINFO[1] = 4
BASH_VERSINFO[2] = 19
BASH_VERSINFO[3] = 1
BASH_VERSINFO[4] = release
BASH_VERSINFO[5] = aarch64-unknown-linux-android
cat /proc/cpuinfo results:
Processor : AArch64 Processor rev 12 (aarch64)
processor : 0
BogoMIPS : 38.40
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp
CPU implementer : 0x51
CPU architecture: 8
CPU variant : 0x7
CPU part : 0x803
CPU revision : 12
processor : 1
BogoMIPS : 38.40
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp
CPU implementer : 0x51
CPU architecture: 8
CPU variant : 0x7
CPU part : 0x803
CPU revision : 12
processor : 2
BogoMIPS : 38.40
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp
CPU implementer : 0x51
CPU architecture: 8
CPU variant : 0x7
CPU part : 0x803
CPU revision : 12
processor : 3
BogoMIPS : 38.40
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp
CPU implementer : 0x51
CPU architecture: 8
CPU variant : 0x7
CPU part : 0x803
CPU revision : 12
processor : 4
BogoMIPS : 38.40
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp
CPU implementer : 0x51
CPU architecture: 8
CPU variant : 0x6
CPU part : 0x802
CPU revision : 13
processor : 5
BogoMIPS : 38.40
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp
CPU implementer : 0x51
CPU architecture: 8
CPU variant : 0x6
processor : 6
BogoMIPS : 38.40
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp
CPU implementer : 0x51
CPU architecture: 8
CPU variant : 0x6
CPU part : 0x802
CPU revision : 13
processor : 7
BogoMIPS : 38.40
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp
CPU implementer : 0x51
CPU architecture: 8
CPU variant : 0x6
CPU part : 0x802
CPU revision : 13
Hardware : Qualcomm Technologies, Inc SDM845
dpkg --print-architecture result:
aarch64
getprop ro.product.cpu.abi result:
arm64-v8a
getprop ro.product.device result:
star2qltecs
Download directory information results.
/sdcard/Download exists
/storage/emulated/0/Download exists
du -hs /data/data/com.termux/files/home/arch results:
124.0K /data/data/com.termux/files/home/arch
ls -al /data/data/com.termux/files/home/arch results:
total 40
drwx------ 9 u0_a290 u0_a290 4096 Apr 5 16:32 .
drwx------ 4 u0_a290 u0_a290 4096 Apr 5 16:36 ..
d--------- 2 u0_a290 u0_a290 4096 Apr 5 16:32 data
d--------- 2 u0_a290 u0_a290 4096 Apr 5 16:32 dev
d--------- 2 u0_a290 u0_a290 4096 Apr 5 16:32 proc
drwx------ 3 u0_a290 u0_a290 4096 Apr 5 16:29 root
d--------- 2 u0_a290 u0_a290 4096 Apr 5 16:32 sdcard
-rwx------ 1 u0_a290 u0_a290 3996 Apr 5 16:29 startarch
d--------- 2 u0_a290 u0_a290 4096 Apr 5 16:32 storage
d--------- 2 u0_a290 u0_a290 4096 Apr 5 16:32 sys
uname -a results:
Linux localhost 4.9.65-13087505 #1 SMP PREEMPT Sun Feb 25 18:48:40 KST 2018 aarch64 Android
End `setupTermuxArchDebug0594.log` debug information.
Post this information along with information regarding your issue at https://github.com/sdrausty/TermuxArch/issues. Include information about input and output. This debugging information is found in /data/data/com.termux/files/home/setupTermuxArchDebug0594.log. If you think screenshots will help in resolving this matter better, include them in your post as well.
Submit this information if you plan to open up an issue at https://github.com/sdrausty/TermuxArch/issues to improve this installation script along with a screenshot of your topic. Include information about input and output.
Thank you for using setupTermuxArch.sh v1.5 ๐
@Root-voidX 'ave you run pkg up
? Upgrade the Termux packages.
Arch error https://imgur.com/a/b9cGw
This is what I get during install. @sdrausty
@aarmn @Root-voidX This commit adds
you should be able to work around this with
export PROOT_NO_SECCOMP=1
From https://github.com/termux/proot/issues/13#issuecomment-379533612 Can you confirm whether this resolves Android 8 installation issues?
@sdrausty So should I just git clone again from scratch?
@Root-voidX yes, that's an option; Any of the methods listed on this https://sdrausty.github.io/TermuxArch/docs/install page should work fine. Use setupTermuxArch.sh purge
first to remove anything left over from the previous attempts.
@sdrausty okay so it extracts properly now but when I try to edit the mirrorlist, even if I type in a second # symbol to point out the mirror it fails to configure and errors pop up during pacman. So I have a feeling I am doing something wrong. Can you advise ?
@sdrausty it seems pacman keyring is failing. I tried reinitializing with pacman-key --init but it still fails.
Termux Arch keyring error https://imgur.com/a/N29tZ
Also due to this using either startarch or ~/arch/startarch fails with a exit code 0
Regards
Due to the fact that this issue is so large; it is forked; Comments are welcome in related forks. https://github.com/sdrausty/TermuxArch/issues/72#issue-315698618 key is for keyring topic.
@Root-voidX see whether setupTermuxArch.sh refresh
helps out with both of the most recent issues. The latest updates should leave topics like:
edit the mirrorlist,
as historical for aarch64 and armv7 architectures, since the default install is now completely automated, including mirrorlist file editing and time zone selection. Should refreshing not help, try reinstalling.
@@sdrausty I did do a reinstall where I deleted everything and reinstalled termux and then all the termux packages along with arch, it says I have insufficient permission to read keyring
@Root-voidX you do not need need to delete everything and reinstall Termux to cleanly install Arch Linux. Running setupTermuxArch.sh purge
is sufficient to completely reinstall Arch Linux in Termux PRoot from scratch. Installing keys is now a separate TermuxArch command keys
. With https://github.com/sdrausty/TermuxArch/commit/1d13cb456d166786e6a5378c42ad634720c67f76 this commit you should have clean installation of Arch Linux in Termux PRoot on all Android versions.
@@sdrausty I did do a reinstall where I deleted everything and reinstalled termux and then all the termux packages along with arch, it says I have insufficient permission to read keyring
@sdrausty my bad I reposted.
Okay say i start from scratch. I install my termux packages along with the required packages like proot, git and wget. Then I follow option 2 from your install readme. I git clone TermuxArch and then run the script. I let the install happen. So does the keyring configure itself now or do I do something? Last time it wouldn't configure no matter how many times I tried on my s9+. Not configuring it breaks the whole arch system.
@sdrausty
Termux Arch error https://imgur.com/a/K4tNQ
The first picture is of me installing termux and the error it produces. The second is of when I use the refresh, error still shows up. This error causes the whole arch system from even working.
Hi @robsmith11, I am having the same problem as you. I saw this bug report
few days ago. I don't understand how you gave ArchLinux in termux access to /dev partition. Can you please tell me how you did it? I tried your command in both ArchLinux and native Android terminal with root but both didn't work. Did you give ArchLinux native root access? If so, how did you do it?
Hi @sdrausty, I hope you don't mind me asking here. I think it will be useful here than in a private conversation. I can't find how to contact robsmith11 any other way.
Hi @kioth are you sure that you want to crack your Android device to use a program? Is your device expendable? Are there any reasonable explanations why a web browser NEEDS access to /dev/shm?
@Root-voidX This https://github.com/sdrausty/TermuxArch/commit/e0dc5185ce8cdee2d5c12d6c183bcac316dc01c0 commit hopefully resolves both the Android 8 issues you mentioned, using bash setupTermuxArch.sh refresh
should suffice. The TermuxArch command keys
generates the keys after logging in. Use keys x86
for x86 devices after logging into Arch Linux in Termux PRoot.
@sdrausty I already have a rooted phone. I already use many root apps. I don't mind using root to run another program. I do understand the risks in using root.
I think normal programs use /dev/shm as temporary storage
. So maybe it's not a very dangerous thing.
@Root-voidX [17:08 hpmor ]$ starte16 & netsurf-gtk3 & texmacs & gimp &
There is a TermuxArch shortcut . exd
to export the display. Screenshot from Android smartphone.
@sdrausty you built in an export display command? Or is this a totally new DE ?
It's just a simple command to setup the exports. For it to work, it must be sourced. That's why the dot .
and space are important. Otherwise, it won't work right:
[19:36 ~ ]$ . exd
[19:36 ~ ]$ export
declare -x DISPLAY=":0"
declare -x PULSE_SERVER="tcp:127.0.0.1:4712"
@kioth
I ended up just using root to do a real chroot into a standard Arch Arm Linux base image from termux. So that included running mount --rbind /dev arch_base/dev
before the chroot and then mkdir /dev/shm; mount -t tmpfs tmpfs /dev/shm
after chrooting.
As you pointed out, I think firefox is just using /dev/shm for temporary storage. So a writable directory there just needs to exist for firefox to be happy -- I don't think it needs to be tmpfs. It might be worth filing a bug with mozilla to make the location configurable, so that /tmp could be used instead.
This the error I get after I followed your steps @sdrausty
@Root-voidX I do not understand your last comment.
1) Is Arch Linux in Termux PRoot installed on the Android 8?
2) Did keys
generate the keys?
A note about root user: Never use the root and similar su accounts for Internet web browsing.
It might be worth filing a bug with mozilla to make the location configurable, so that /tmp could be used instead.
Sounds like a good idea and it might be a solution to get Firefox working. This file .mozilla/firefox/profiles.ini
is a good candidate for this option @robsmith11
@sdrausty
Oh sorry I guess the link didn't go through. Keyring error https://imgur.com/a/26Fed
So the arch system did not install and keys failed to generate anything. Without keys being generated the arch system doesn't fully install.
Edit 1: using pacman-key --unit doesn't help either
- How do I get software rendering so I can run gui app?
@root-voidX, Using noVNC+tigervnc instead of XServer XSDL saves the need to install an external app. Access gui apps from any already-installed web browser.
# lxde + fix, as before
pacman -S lxde
pacman -S ttf-dejavu
# vnc server
pacman -S tigervnc
# html5 vnc client
curl -O https://github.com/novnc/noVNC/archive/v1.0.0.tar.gz
tar xvfz v1.0.0.tar.gz
# run vnc. make sure display & vnc port match
export DISPLAY=:7
export VNC_PORT=5907
Xvnc --localhost --SecurityTypes=None $DISPLAY &
cd noVNC-1.0.0; ./utils/launch.sh --vnc localhost:$VNC_PORT &
startlxde
echo "To see the magic, point your favorite browser to http://127.0.0.1:6080/vnc.html"
@Root-voidX this https://github.com/sdrausty/TermuxArch/commit/8c70e4ee72be6a14f5b8647f364c2a3696738942 commit adds archlinuxarm-keyring to keys. One of the errors may be related to:
rm -rf /etc/pacman.d/gnupg ||:
in keys
. Tweeking or possibly removing rm -rf /etc/pacman.d/gnupg ||:
might fix the error. The keys install correctly as far as I can tell; More information about installing keys at:
https://github.com/termux/proot/issues/10 https://github.com/sdrausty/TermuxArch/issues/28 https://github.com/sdrausty/TermuxArch/issues/33 https://github.com/sdrausty/TermuxArch/issues/46 edit: https://github.com/sdrausty/TermuxArch/issues/72
@Root-voidX this https://github.com/sdrausty/TermuxArch/commit/43a241997c91be65c6c8c860499b6ac9c6ced36b commit removes rm -rf /etc/pacman.d/gnupg ||:
from keys
and might resolve the issue on Android 8. Use setupTermuxArch.sh purge
to remove the current system followed by setupTermuxArch.sh
. After Arch Linux in Termux PRoot is reinstalled, use keys
to generate the keys.
Without keys being generated the arch system doesn't fully install.
Can you explain this in detail? What does not install? The keys are necessary for... I need them because...
@sdrausty I will retry, the issue is without keyring this error happens. https://i.imgur.com/rGuJuET.jpg. it seems dude to the keyring permission error it can't read or alter the /boot/image and this causes all packages to fail.
@iL3D tried your instructions repeatedly with variations; The best I get is:
Failed to connect to server
In the web browser, and:
$ DISPLAY=$LOCAL_ARCH startlxde
** Message: 01:02:57.431: main.vala:102: Session is LXDE
** Message: 01:02:57.435: main.vala:103: DE is LXDE
(lxsession:8047): Gtk-WARNING **: 01:02:57.461: cannot open display:
@Root-voidX
Edit 1: using pacman-key --unit doesn't help either
$ pacman-key --unit
pacman-key: invalid option '--unit'
i mean pacman-key --init
@Root-voidX thanks for clarifying. How is the latest version of keys
working for you on Android 8?
Hey @sdrausty thanks for the response. I looked into it again.
So during initial setup I get this error: https://i.imgur.com/wIxmz6B.jpg
Now I can't tell what exactly these errors means. Either android 8 is suppressing premissions or the untar process is borked.
Regarding the usage of keys command, I get this error: https://i.imgur.com/5NNxYbZ.jpg
It seems gpg is having a fatal error. No doubt related to android 8 security changes.
I can easily exit and enter arch proot but due to the issues listed the arch install is useless because no packages will install. This error arises when I try to install in anything: https://i.imgur.com/DxEpiyH.jpg
Hopefully this helps! I looked around and it seems ubuntu in proot has similar issues.
@Root-voidX you are welcome; Can you share the output of the following three startarch
commands?
[17:35 ~ ]$ startarch command "pwd & whoami"
/data/data/com.termux/files/home
root
[17:35 ~ ]$ startarch command addauser user
Welcome to Arch Linux in Termux! Enjoy!
Chat: https://gitter.im/termux/termux/
Help: info query and man query
Portal: https://wiki.termux.com/wiki/Community
Install a package: pacman -S package
More information: pacman [-D|F|Q|R|S|T|U]h
Search packages: pacman -Ss query
Upgrade packages: pacman -Syu
[17:36 ~ ]$ e
[17:36 ~ ]$ startarch su user "pwd & whoami"
/home/user
user
If the output is different, this will be a good clue as to what is going on. Note the double quotation marks in the first and third startarch
command constructs.
Hey @sdrausty I finally checked out Arch. I have used Mandrake on PC before so I like to think I know a bit or too about Linux. Anyway I have a few questions I hope you could answer:
Thanks my dude!