Coder Social home page Coder Social logo

termux-ubuntu's Introduction

termux-ubuntu

A script to install Ubuntu chroot in Termux

You need to install wget and proot in Termux before using this script.

pkg install wget proot

The script will make its files in the current directory. So if you want your Ubuntu-filesystem at a particular location switch to that folder first and then call the script with it's relative path. Example:

mkdir -p ~/jails/ubuntu
cd ~/jails/ubuntu
wget https://raw.githubusercontent.com/Neo-Oli/termux-ubuntu/master/ubuntu.sh
bash ubuntu.sh

After running it you can run "start-ubuntu.sh" to switch into your ubuntu

termux-ubuntu's People

Contributors

brysgo avatar casept avatar clirimfurriku avatar dmole avatar jhnewa avatar monoidic avatar neo-oli avatar spcharc avatar yeongheon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

termux-ubuntu's Issues

sdcard

cannot access sdcard.

nmap still version 7.60

the latest and greatest is 7.70 though....


root@localhost:~# apt install nmap
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
  ndiff
The following NEW packages will be installed:
  nmap
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 5118 kB of archives.
After this operation, 23.9 MB of additional disk space will be used.
Get:1 http://ports.ubuntu.com/ubuntu-ports bionic/main arm64 nmap arm64 7.60-1ubuntu5 [5118 kB]
Fetched 5118 kB in 20s (257 kB/s)
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76, <> line 1.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (Can't locate Term/ReadLine.pm in @INC (you may need to install the Term::ReadLine module) (@INC contains: /etc/perl /usr/local/lib/aarch64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/aarch64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/aarch64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/aarch64-linux-gnu/perl-base) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7, <> line 1.)
debconf: falling back to frontend: Teletype
E: Setting in Start via TCSAFLUSH for stdin failed! - tcsetattr (13: Permission denied)
Selecting previously unselected package nmap.
(Reading database ... 4601 files and directories currently installed.)
Preparing to unpack .../nmap_7.60-1ubuntu5_arm64.deb ...
Unpacking nmap (7.60-1ubuntu5) ...
Setting up nmap (7.60-1ubuntu5) ...
root@localhost:~#

Error after first installation at ./start.sh

I love ubuntu and it would be incredible to make it run on my galaxy s7 without root permission. I installed pkg install proot and pkg install termux-exec but I am not able to open ubuntu. Please help, i might oversee something.

"making start.sh executable
You can now launch Ubuntu with the ./start.sh script
$ ./start.sh
proot warning: can't chdir("/root/.") in the guest rootfs: No such file or directory
proot info: default working directory is now "/"
proot error: '/usr/bin/env' not found (root = /data/data/com.termux/files/home/ubuntu-fs, cwd = /, $PATH=(null))
fatal error: see proot --help.
$ PROOT_NO_SECCOMP=1 termux-chroot
$ ./start.sh
proot warning: can't sanitize binding "/sys/": No such file or directory
proot warning: can't chdir("/root/.") in the guest rootfs: No such file or directory
proot info: default working directory is now "/"
proot error: '/usr/bin/env' not found (root = /home/ubuntu-fs, cwd = /, $PATH=(null))
fatal error: see proot --help.
proot error: trying to remove a directory outside of '/data/data/com.termux/files/usr/tmp/', please report this error.

$ apt update && apt upgradE"

Vim or neovim does not work properly

I can't edit any file in vim or any of its derivatives like vim-gnome or neovim.I can successfully open the insert mood but then cannot move the prompt to any position.

#Help

dpkg error when running apt upgrade or apt install anything due to short installed packages please fix!

Error after first installation at ./start.sh

I love ubuntu and it would be incredible to make it run on my galaxy s7 without root permission. I installed pkg install proot and pkg install termux-exec but I am not able to open ubuntu. Please help, i might oversee something.

"making start.sh executable
You can now launch Ubuntu with the ./start.sh script
$ ./start.sh
proot warning: can't chdir("/root/.") in the guest rootfs: No such file or directory
proot info: default working directory is now "/"
proot error: '/usr/bin/env' not found (root = /data/data/com.termux/files/home/ubuntu-fs, cwd = /, $PATH=(null))
fatal error: see proot --help.
$ PROOT_NO_SECCOMP=1 termux-chroot
$ ./start.sh
proot warning: can't sanitize binding "/sys/": No such file or directory
proot warning: can't chdir("/root/.") in the guest rootfs: No such file or directory
proot info: default working directory is now "/"
proot error: '/usr/bin/env' not found (root = /home/ubuntu-fs, cwd = /, $PATH=(null))
fatal error: see proot --help.
proot error: trying to remove a directory outside of '/data/data/com.termux/files/usr/tmp/', please report this error.

$ apt update && apt upgradE"

groups: cannot find name for group ID

$ ./startubuntu.sh
groups: cannot find name for group ID 1015
groups: cannot find name for group ID 1023
groups: cannot find name for group ID 1028
groups: cannot find name for group ID 3003
groups: cannot find name for group ID 9997
groups: cannot find name for group ID 50020
root@localhost:~# exit
logout

I get error while extracting file with tar, there was 6 file not extracted. I start ubuntu and get that error. So i extract ubuntu.tar.gz again with tar command, i get the 6 file back but the error still appear, is this not related with that error? I am new on linux, thank you.

nmap fails

is it because I am rootless?
But am I not root inside termubu?

$ ./start-ubuntu.sh
groups: cannot find name for group ID 3003
groups: cannot find name for group ID 9997
groups: cannot find name for group ID 20251
groups: cannot find name for group ID 50251

root@localhost:~# nmap localhost
Starting Nmap 7.60 ( https://nmap.org ) at 2018-07-15 16:39 UTC
nmap: netutil.cc:3285: int route_dst_netlink(const sockaddr_storage*, route_nfo*, const char*, const sockaddr_storage*): Assertion `p != NULL' failed.
Aborted

root@localhost:~# nmap 127.0.0.1
Starting Nmap 7.60 ( https://nmap.org ) at 2018-07-15 16:41 UTC
nmap: netutil.cc:3285: int route_dst_netlink(const sockaddr_storage*, route_nfo*, const char*, const sockaddr_storage*): Assertion `p != NULL' failed.
Aborted

root@localhost:~# exit
logout

$ nmap localhost
Starting Nmap 7.70 ( https://nmap.org ) at 2018-07-15 12:40 EDT
Nmap scan report for localhost (127.0.0.1)
Host is up (0.016s latency).
Not shown: 999 closed ports
PORT     STATE SERVICE
6666/tcp open  irc

Nmap done: 1 IP address (1 host up) scanned in 2.19 seconds
$


termux-ubuntu(Cannot open audit interface - aborting.)

Cannot open audit interface - aborting.
addgroup: `/usr/sbin/groupadd -g 101 systemd-journal' returned error code 1. Exiting.
dpkg: error processing package systemd (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
systemd
E: Sub-process /usr/bin/dpkg returned an error code (1)
How do I fix this

Git error on binded folder.: unable to write sha1 filename

Hi, That's great project and I'm liking it.

I got a sdcard/storage bind folder using a file inside the binds folder. It looks like this:

command+=" -b $HOME/storage/downloads"
command+=" -b $HOME/storage/shared/Projects"

It's working except when I'm trying to use git clone inside one of these folders. I got an error
error: unable to write sha1 filename /data/data/com.termux/files/home/storage/shared/Projects/....pack: No such file or directory fatal: cannot store pack file fatal: index-pack failed

If I git clone out of these binded folders, I can have a working repo, but when I move it to one of these folders I got many lines like this:
mv: preserving times for 'projects/.../.git/branches': Operation not permitted

And after it, git thinks I had changed some files of this repository. The way I found to workaround it was git clone at termux terminal and only after that starting ubuntu. I didn't test if pull/push is working yet. I think this other project has something relate to this problem https://github.com/corbinlc/GNURootDebian/issues/105.

/proc is not mounted?

./start-ubuntu.sh
groups: cannot find name for group ID 3003
groups: cannot find name for group ID 9997
groups: cannot find name for group ID 20251
groups: cannot find name for group ID 50251

root@localhost:# ps -aT
Error: /proc must be mounted
To mount /proc at boot you need an /etc/fstab line like:
proc /proc proc defaults
In the meantime, run "mount proc /proc -t proc"
root@localhost:
#
root@localhost:#
root@localhost:
#
root@localhost:#
root@localhost:
# mount
rootfs on / type rootfs (ro,seclabel,size=1651280k,nr_inodes=412820)
tmpfs on /dev type tmpfs (rw,nosuid,relatime,seclabel,size=1718764k,nr_inodes=429691,mode=755)
devpts on /dev/pts type devpts (rw,relatime,seclabel,mode=600)
none on /dev/cpuctl type cgroup (rw,relatime,cpu)
none on /dev/cpuset type cgroup (rw,relatime,cpuset,noprefix,release_agent=/sbin/cpuset_release_agent)
adb on /dev/usb-ffs/adb type functionfs (rw,relatime)
proc on /proc type proc (rw,relatime,gid=3009,hidepid=2)
sysfs on /sys type sysfs (rw,relatime,seclabel)
selinuxfs on /sys/fs/selinux type selinuxfs (rw,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,relatime,seclabel)
tracefs on /sys/kernel/debug/tracing type tracefs (rw,relatime,seclabel)
pstore on /sys/fs/pstore type pstore (rw,relatime,seclabel)
/dev/block/dm-0 on /system type ext4 (ro,relatime,seclabel,norecovery)
none on /acct type cgroup (rw,relatime,cpuacct)
tmpfs on /mnt type tmpfs (rw,relatime,seclabel,size=1718764k,nr_inodes=429691,mode=755,gid=1000)
tmpfs on /mnt/secure type tmpfs (rw,relatime,seclabel,size=1718764k,nr_inodes=429691,mode=700)
/data/knox/sdcard/150 on /mnt/knox/default/emulated/150 type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=1015,mask=6,userid=150,reserved=20MB)
/data/knox/sdcard/150 on /mnt/knox/read/emulated/150 type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=9997,mask=23,userid=150,reserved=20MB)
/data/knox/sdcard/150 on /mnt/knox/write/emulated/150 type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=9997,mask=7,userid=150,reserved=20MB)
/data/media on /mnt/runtime/default/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=1015,multiuser,mask=6,reserved=20MB)
/data/media on /mnt/runtime/read/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=9997,multiuser,mask=23,reserved=20MB)
/data/media on /mnt/runtime/write/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=9997,multiuser,mask=7,reserved=20MB)
/data/knox/secure_fs/enc_media on /mnt/shell/enc_emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1000,fsgid=1000,gid=9997,multiuser,reserved=20MB)
none on /config type configfs (rw,relatime)
/dev/block/bootdevice/by-name/cache on /cache type ext4 (rw,nosuid,nodev,noatime,seclabel,journal_checksum,journal_async_commit,noauto_da_alloc)
/dev/block/bootdevice/by-name/persist on /persist type ext4 (rw,nosuid,nodev,noatime,seclabel)
/dev/block/bootdevice/by-name/efs on /efs type ext4 (rw,nosuid,nodev,noatime,seclabel,journal_checksum,journal_async_commit,noauto_da_alloc)
/dev/block/bootdevice/by-name/dsp on /dsp type ext4 (ro,nosuid,nodev,relatime,seclabel,data=ordered)
/dev/block/bootdevice/by-name/apnhlos on /firmware type vfat (ro,relatime,context=u:object_r:firmware_file:s0,uid=1000,gid=1000,fmask=0337,dmask=0227,codepage=437,iocharset=iso8859-1,shortname=lower,errors=remount-ro)
/dev/block/bootdevice/by-name/modem on /firmware-modem type vfat (ro,relatime,context=u:object_r:firmware_file:s0,uid=1000,gid=1000,fmask=0337,dmask=0227,codepage=437,iocharset=iso8859-1,shortname=lower,errors=remount-ro)
/dev/block/dm-1 on /data type ext4 (rw,nosuid,nodev,noatime,seclabel,journal_checksum,journal_async_commit,noauto_da_alloc)
/data/knox/data_de/150 on /data/user_de/150 type ecryptfs (rw,nodev,relatime,seclabel,ecryptfs_sig=694146088d1555d7,userid=150,sdp_enabled,partition_id=0,ecryptfs_cipher=aes,ecryptfs_key_bytes=32,ecryptfs_enable_cc,ecryptfs_passthrough,base=,label=)
/data/knox/misc_de/150 on /data/misc_de/150 type ecryptfs (rw,nodev,relatime,seclabel,ecryptfs_sig=694146088d1555d7,userid=150,sdp_enabled,partition_id=1,ecryptfs_cipher=aes,ecryptfs_key_bytes=32,ecryptfs_enable_cc,ecryptfs_passthrough,base=,label=)
/data/knox/system_de/150 on /data/system_de/150 type ecryptfs (rw,nodev,relatime,seclabel,ecryptfs_sig=694146088d1555d7,userid=150,sdp_enabled,partition_id=2,ecryptfs_cipher=aes,ecryptfs_key_bytes=32,ecryptfs_enable_cc,ecryptfs_passthrough,base=,label=)
/data/knox/data/150 on /data/user/150 type ecryptfs (rw,nodev,relatime,seclabel,ecryptfs_sig=06d4724190970209,userid=150,sdp_enabled,partition_id=3,ecryptfs_cipher=aes,ecryptfs_key_bytes=32,ecryptfs_enable_cc,ecryptfs_passthrough,base=,label=)
/data/knox/sdcard/150 on /data/knox/sdcard/150 type ecryptfs (rw,nodev,relatime,seclabel,ecryptfs_sig=06d4724190970209,userid=150,sdp_enabled,partition_id=4,dlp_enabled,ecryptfs_cipher=aes,ecryptfs_key_bytes=32,ecryptfs_enable_cc,ecryptfs_passthrough,base=,label=)
/data/knox/misc_ce/150 on /data/misc_ce/150 type ecryptfs (rw,nodev,relatime,seclabel,ecryptfs_sig=06d4724190970209,userid=150,sdp_enabled,partition_id=5,ecryptfs_cipher=aes,ecryptfs_key_bytes=32,ecryptfs_enable_cc,ecryptfs_passthrough,base=,label=)
/data/knox/system_ce/150 on /data/system_ce/150 type ecryptfs (rw,nodev,relatime,seclabel,ecryptfs_sig=06d4724190970209,userid=150,sdp_enabled,partition_id=6,ecryptfs_cipher=aes,ecryptfs_key_bytes=32,ecryptfs_enable_cc,ecryptfs_passthrough,base=,label=)
/data/knox/secure_fs/enc_user on /data/enc_user type ecryptfs (rw,nodev,relatime,seclabel,ecryptfs_fnek_sig=a692cd761731acfd,ecryptfs_sig=a692cd761731acfd,userid=0,sdp_enabled,partition_id=7,ecryptfs_cipher=aes,ecryptfs_key_bytes=32,ecryptfs_enable_cc,ecryptfs_passthrough,base=,label=)
/data/knox/secure_fs/enc_media on /data/knox/secure_fs/enc_media type ecryptfs (rw,nodev,relatime,seclabel,ecryptfs_fnek_sig=a692cd761731acfd,ecryptfs_sig=a692cd761731acfd,userid=0,sdp_enabled,partition_id=8,ecryptfs_cipher=aes,ecryptfs_key_bytes=32,ecryptfs_enable_cc,ecryptfs_passthrough,base=,label=)
tmpfs on /storage type tmpfs (rw,relatime,seclabel,size=1718764k,nr_inodes=429691,mode=755,gid=1000)
/data/media on /storage/emulated type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=9997,multiuser,mask=7,reserved=20MB)
/data/knox/sdcard/150 on /storage/emulated/150 type sdcardfs (rw,nosuid,nodev,noexec,noatime,fsuid=1023,fsgid=1023,gid=9997,mask=7,userid=150,reserved=20MB)
tmpfs on /storage/self type tmpfs (rw,relatime,seclabel,size=1718764k,nr_inodes=429691,mode=755,gid=1000)
root@localhost:~#

test

wrong terminal set inside adb shell

What terminal should I set if I go to the adb shell from within termux-ubuntu?

Welcome to Termux!

$ nmap localhost
Starting Nmap 7.70 ( https://nmap.org ) at 2018-07-12 22:49 EDT
Nmap scan report for localhost (127.0.0.1)
Host is up (0.0085s latency).
Not shown: 999 closed ports
PORT     STATE SERVICE
6666/tcp open  irc

Nmap done: 1 IP address (1 host up) scanned in 2.75 seconds
$
$
$ cd termux-ubuntu/
$ ./start-ubuntu.sh
groups: cannot find name for group ID 3003
groups: cannot find name for group ID 9997
groups: cannot find name for group ID 20251
groups: cannot find name for group ID 50251
root@localhost:~#
root@localhost:~#
root@localhost:~# adb reconnect
done
root@localhost:~#
root@localhost:~# adb connect localhost:6666
connected to localhost:6666
root@localhost:~# adb shell
gts3lwifi:/ $
gts3lwifi:/ $
gts3lwifi:/ $ ^[[A

If I hit tab or any cursor key, some ascii codes are shown as seen above.

**

gts3lwifi:/sdcard/Download/bugs $ set
set
ANDROID_ASSETS=/system/app
ANDROID_BOOTLOGO=1
ANDROID_DATA=/data
ANDROID_ROOT=/system
ANDROID_SOCKET_adbd=8
ANDROID_STORAGE=/storage
ASEC_MOUNTPOINT=/mnt/asec
BASHPID=2843
BOOTCLASSPATH=/system/framework/QPerformance.jar:/system/framework/SmpsManager.jar:/system/framework/core-oj.jar:/system/framework/core-libart.jar:/system/framework/conscrypt.jar:/system/framework/okhttp.jar:/system/framework/legacy-test.jar:/system/framework/bouncycastle.jar:/system/framework/ext.jar:/system/framework/framework.jar:/system/framework/telephony-common.jar:/system/framework/voip-common.jar:/system/framework/ims-common.jar:/system/framework/apache-xml.jar:/system/framework/org.apache.http.legacy.boot.jar:/system/framework/smartbondingservice.jar:/system/framework/sprengine.jar:/system/framework/android.hidl.base-V1.0-java.jar:/system/framework/android.hidl.manager-V1.0-java.jar:/system/framework/timakeystore.jar:/system/framework/fipstimakeystore.jar:/system/framework/ucmopensslenginehelper.jar:/system/framework/esecomm.jar:/system/framework/SemAudioThumbnail.jar:/system/framework/knoxsdk.jar:/system/framework/sec_edm.jar:/system/framework/sagearpolicymanager.jar:/system/framework/sec_sdp_sdk.jar:/system/framework/sec_sdp_hidden_sdk.jar:/system/framework/knoxvpnuidtag.jar:/system/framework/tcmiface.jar:/system/framework/telephony-ext.jar:/system/framework/WfdCommon.jar:/system/framework/oem-services.jar:/system/framework/qcom.fmradio.jar
COLUMNS
DOWNLOAD_CACHE=/data/cache
ENC_EMULATED_STORAGE_TARGET=/storage/enc_emulated
EPOCHREALTIME=1531451592.225526
EXTERNAL_STORAGE=/sdcard
HOME=/
HOSTNAME=gts3lwifi
IFS=$' \t\n'
KNOX_STORAGE=/data/knox/ext_sdcard
KSHEGID=2000
KSHGID=2000
KSHUID=2000
KSH_VERSION='@(#)MIRBSD KSH R54 2016/11/11'
LINES
LOGNAME=shell
MC_AUTH_TOKEN_PATH=/efs/TEE
OLDPWD=/
OPTIND=1
PATH=/sbin:/system/sbin:/system/bin:/system/xbin:/vendor/bin:/vendor/xbin
PGRP=2843
PIPESTATUS[0]=1
PPID=8283
PS1=$'${|\n\tlocal e=$?\n\n\t(( e )) && REPLY+="$e|"\n\n\treturn $e\n}$HOSTNAME:${PWD:-?} $ '
PS2='> '
PS3='#? '
PS4='[$EPOCHREALTIME] '
PWD=/sdcard/Download/bugs
RANDOM=30688
SECONDS=35
SHELL=/system/bin/sh
SYSTEMSERVERCLASSPATH=/system/framework/services.jar:/system/framework/ethernet-service.jar:/system/framework/wifi-service.jar:/system/framework/samsung-services.jar:/system/framework/hqm.jar:/system/framework/dmf.jar:/system/framework/ssrm.jar
TERM=xterm-256color
TMOUT=0
TMPDIR=/data/local/tmp
USER=shell
USER_ID=2000
_=set
gts3lwifi:

**

sorry one more issue

i cant seem to install any packages it says unable to fetch some archives. what should i do

Can i used Ubuntu Zesty Z. Instead Artfull?

How to used Zasty Image Instead of Artfull Ardvard?

Recently i read some blog post about termux Ubuntu, some of the writer, they are mention About Ubuntu Zasty instead of Artfull.

Maybe i can update repository in termux if i used older version of Ubuntu?

Cannot run VNC Server

Hi,

I installed LXDE user interface and tightvncserver.

When i run vnc server with command:
tightvncserver :1
A message appears:
The user environment variable is not set

Do someone know why?
Or do you know how to install a user interface reacheable by vnc?

Thanks

Ping does not work

there is no module named ping in Ubuntu here.Add some module for ping

frontend / UI dialog expected?

Can I fix this with dpkg?
The upgrade seems to be unaffected.

`The following packages will be upgraded:
libssl1.0.0 libssl1.1
2 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 1637 kB of archives.
After this operation, 3072 B disk space will be freed.
Do you want to continue? [Y/n]
Get:1 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 libssl1.1 arm64 1.1.0g-2ubuntu4.1 [915 kB]
Get:2 http://ports.ubuntu.com/ubuntu-ports bionic-updates/main arm64 libssl1.0.0 arm64 1.0.2n-1ubuntu5.1 [722 kB]
Fetched 1637 kB in 4s (398 kB/s)
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76, <> line 2.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (Can't locate Term/ReadLine.pm in @inc (you may need to install the Term::ReadLine module) (@inc contains: /etc/perl /usr/local/lib/aarch64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/aarch64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/aarch64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/aarch64-linux-gnu/perl-base) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7, <> line 2.)
debconf: falling back to frontend: Teletype
Preconfiguring packages ...
E: Setting in Start via TCSAFLUSH for stdin failed! - tcsetattr (13: Permission denied)
(Reading database ... 5412 files and directories currently installed.)
Preparing to unpack .../libssl1.1_1.1.0g-2ubuntu4.1_arm64.deb ...
Unpacking libssl1.1:arm64 (1.1.0g-2ubuntu4.1) over (1.1.0g-2ubuntu4) ...
Preparing to unpack .../libssl1.0.0_1.0.2n-1ubuntu5.1_arm64.deb ...
Unpacking libssl1.0.0:arm64 (1.0.2n-1ubuntu5.1) over (1.0.2n-1ubuntu5) ...
Setting up libssl1.0.0:arm64 (1.0.2n-1ubuntu5.1) ...
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (Can't locate Term/ReadLine.pm in @inc (you may need to install the Term::ReadLine module) (@inc contains: /etc/perl /usr/local/lib/aarch64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/aarch64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/aarch64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/aarch64-linux-gnu/perl-base) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.)
debconf: falling back to frontend: Teletype
Processing triggers for libc-bin (2.27-3ubuntu1) ...
Setting up libssl1.1:arm64 (1.1.0g-2ubuntu4.1) ...
debconf: unable to initialize frontend: Dialog
debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.)
debconf: falling back to frontend: Readline
debconf: unable to initialize frontend: Readline
debconf: (Can't locate Term/ReadLine.pm in @inc (you may need to install the Term::ReadLine module) (@inc contains: /etc/perl /usr/local/lib/aarch64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/aarch64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/aarch64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/aarch64-linux-gnu/perl-base) at /usr/share/perl5/Debconf/FrontEnd/Readline.pm line 7.)
debconf: falling back to frontend: Teletype
Processing triggers for libc-bin (2.27-3ubuntu1) ...
root@localhost:~#'

/dev/random unseeded

In order to use ssh, there needs to be random data in /dev/random, not sure the best way to get it there.

Failed to setgroups

I tried to install snapd (and a bunch of other apps), but I can't install anything.

…
0 upgraded, 100 newly installed, 0 to remove and 0 not upgraded.
Need to get 38.1 MB of archives.
After this operation, 177 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
E: setgroups 65534 failed - setgroups (38: Function not implemented)
E: setegid 65534 failed - setegid (38: Function not implemented)
E: setegid 0 failed - setegid (38: Function not implemented)
E: setgroups 0 failed - setgroups (38: Function not implemented)
E: setgroups 65534 failed - setgroups (38: Function not implemented)
E: setegid 65534 failed - setegid (38: Function not implemented)
E: setegid 0 failed - setegid (38: Function not implemented)
E: setgroups 0 failed - setgroups (38: Function not implemented)
E: Method gave invalid 400 URI Failure message: Failed to setgroups - setgroups (38: Function not implemented)
E: Method http has died unexpectedly!
E: Sub-process http returned an error code (112)

architecture discrepancy

root@localhost:~# uname -a
Linux localhost 3.18.71-13482624 #1 SMP PREEMPT Fri May 4 20:47:19 KST 2018 aarch64 aarch64 aarch64 GNU/Linux

root@localhost:#
root@localhost:
# dpkg --print-architecture
arm64

aarch64 or arm64?

probably both?

Your script is wrong... shebang issue and proot issue

$ ./start.sh
proot warning: can't chdir("/root/.") in the guest rootfs: No such file or directory
proot info: default working directory is now "/"
proot error: '/usr/bin/env' not found (root = /data/data/com.termux/files/home/termux-ubuntu/ubuntu-fs, cwd = /, $PATH=(null))
fatal error: see proot --help.
$

Support for glances

python based app glances does not work in Ubuntu.

Glances issue for termux-ubuntu

It shows not found any path for

/etc/mtab 

dpkg-statoverride: error

when I'm trying to upgrade, throwing this error

dpkg-statoverride: error: group 'messagebus' does not exist

adduser doesn't work

Hi,
I've following error when I trying install firebird.

Cannot open audit interface - aborting.
adduser: '/usr/sbin/groupadd -g 101 firebird' returned error code 1. Exiting.
dpkg: error processing packagefirebird3.0-server (--configure)
....

How can I solve this problem?
Thanks in advance.

Android 8.0 snapdragon 845 s9+ issues

Hey guys i thought this might warrent its own post. I installed ubuntu with no issues. But during startup, there are these errors:

groups: cannot find name for group ID 3003
groups: cannot find name for group ID 9997
groups: cannot find name for group ID 20290
groups: cannot find name for group ID 50290

I looked into it on this github and found someone say this is just a warning and ubuntu has already loaded the groups. I then run into an issue with installing or updating anything. Dpkg aborts saying the error is in system md. So idk what wrong.

Can someone help me look into this?

error after downloading ubuntu.tar.gz

Hello, the script is giving errors after downloading ubuntu.tar.gz:

decompresing ubuntu image
tar: can't create node dev/random: Operation not permitted
tar: can't create node dev/urandom: Operation not permitted
tar: can't create node dev/null: Operation not permitted
tar: can't create node dev/tty: Operation not permitted
tar: can't create node dev/zero: Operation not permitted
tar: can't create node dev/full: Operation not permitted

And if i run start.sh after this, i got:

groups: cannot find name foro group ID 1015
groups: cannot find name foro group ID 1023
groups: cannot find name foro group ID 1028
groups: cannot find name foro group ID 3003
groups: cannot find name foro group ID 9997
groups: cannot find name foro group ID 50005
mesg: change /edv/pts/0 mode failed: permission denied

need help getting 64-bit running

Hey @Neo-Oli - thanks again for this stuff, I find myself coming back to it often. I am trying to install 64 bit ubuntu on my chromebook pixel 2 (i686) so I made some small changes to your install script. I get an error from proot that it can't run 64 bit programs.

		amd64)
			archurl="amd64" ;;
+		i686)
+			archurl="amd64" ;;
+		i386)
-		i*86)
			archurl="i386" ;;
		*)
			echo "unknown architecture"; exit 1 ;;
		esac
+		wget "https://partner-images.canonical.com/core/cosmic/current/ubuntu-cosmic-core-cloudimg-${archurl}-root.tar.gz" -O $tarball
-		wget "https://partner-images.canonical.com/core/bionic/current/ubuntu-bionic-core-cloudimg-${archurl}-root.tar.gz" -O $tarball
	fi
	cur=`pwd`

screenshot 2018-05-13 at 2 24 30 am

bsdutils package corrupt / apt upgrade aborts

`//
// termux
//
$ dpkg --print-architecture
aarch64

//
// calling ubuntski
//
$ ./start-ubuntu.sh
groups: cannot find name for group ID 3003
groups: cannot find name for group ID 9997
groups: cannot find name for group ID 20251
groups: cannot find name for group ID 50251
root@localhost:~#

root@localhost:# dpkg --print-architecture
arm64
root@localhost:
#
root@localhost:~# apt update
Hit:1 http://ports.ubuntu.com/ubuntu-ports bionic InRelease
Hit:2 http://ports.ubuntu.com/ubuntu-ports bionic-updates InRelease
Hit:3 http://ports.ubuntu.com/ubuntu-ports bionic-backports InRelease
Hit:4 http://ports.ubuntu.com/ubuntu-ports bionic-security InRelease
Reading package lists... Done
Building dependency tree
Reading state information... Done
13 packages can be upgraded. Run 'apt list --upgradable' to see them.

root@localhost:#
root@localhost:
# apt list --upgradable
Listing... Done
fdisk/bionic-updates 2.31.1-0.4ubuntu3.1 arm64 [upgradable from: 2.31.1-0.4ubuntu3]
libblkid1/bionic-updates 2.31.1-0.4ubuntu3.1 arm64 [upgradable from: 2.31.1-0.4ubuntu3]

libfdisk1/bionic-updates 2.31.1-0.4ubuntu3.1 arm64 [upgradable from: 2.31.1-0.4ubuntu3]
libmount1/bionic-updates 2.31.1-0.4ubuntu3.1 arm64 [upgradable from: 2.31.1-0.4ubuntu3]
libncurses5/bionic-updates 6.1-1ubuntu1.18.04 arm64 [upgradable from: 6.1-1ubuntu1]
libncursesw5/bionic-updates 6.1-1ubuntu1.18.04 arm64 [upgradable from: 6.1-1ubuntu1]
libsmartcols1/bionic-updates 2.31.1-0.4ubuntu3.1 arm64 [upgradable from: 2.31.1-0.4ubuntu3]
libtinfo5/bionic-updates 6.1-1ubuntu1.18.04 arm64 [upgradable from: 6.1-1ubuntu1]
libuuid1/bionic-updates 2.31.1-0.4ubuntu3.1 arm64 [upgradable from: 2.31.1-0.4ubuntu3]
mount/bionic-updates 2.31.1-0.4ubuntu3.1 arm64 [upgradable from: 2.31.1-0.4ubuntu3]
ncurses-base/bionic-updates 6.1-1ubuntu1.18.04 all [upgradable from: 6.1-1ubuntu1]
ncurses-bin/bionic-updates 6.1-1ubuntu1.18.04 arm64 [upgradable from: 6.1-1ubuntu1]
util-linux/bionic-updates 2.31.1-0.4ubuntu3.1 arm64 [upgradable from: 2.31.1-0.4ubuntu3]

root@localhost:#
root@localhost:
#
root@localhost:~# apt upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages will be upgraded:
 fdisk libblkid1 libfdisk1 libmount1 libncurses5 libncursesw5 libsmartcols1 libtinfo5 libuuid1
 mount ncurses-base ncurses-bin util-linux
13 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
3 not fully installed or removed.
Need to get 0 B/2165 kB of archives.
After this operation, 18.4 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
debconf: delaying package configuration, since apt-utils is not installed
E: Setting in Start via TCSAFLUSH for stdin failed! - tcsetattr (13: Permission denied)
dpkg: error processing package bsdutils (--configure):
package is in a very bad inconsistent state; you should
reinstall it before attempting configuration
Errors were encountered while processing:
bsdutils
E: Sub-process /usr/bin/dpkg

`

access to the home directory of termux

command+=" -b /dev"
command+=" -b /proc"
///////uncomment the following line to have access to the home directory of termux
command+=" -b /data/data/com.termux/files/home:/root"
command+=" -w /root"
command+=" /usr/bin/env -i"
command+=" HOME=/root"
command+=" PATH=/usr/local/sbin:/usr/local/bin:/bin:/usr/bin:/sbin:/usr/sbin:/usr/games:/usr/local/games"
command+=" TERM=$TERM"
command+=" LANG=C.UTF-8"
command+=" /bin/bash --login"

however, the 'downloads' folder is erroneously pointing to the root of ubuntu and not the root of termux as expected.

$ pwd
/data/data/com.termux/files/home/termux-ubuntu
$
$ ./start-ubuntu.sh
groups: cannot find name for group ID 3003
groups: cannot find name for group ID 9997
groups: cannot find name for group ID 20321
groups: cannot find name for group ID 50321
root@localhost:#
root@localhost:
# ls -altr
total 88
drwx------. 2 root root 4096 Feb 13 10:24 storage
drwx------. 5 root root 4096 May 12 03:39 termux-ubuntu
drwx------. 2 root root 4096 Jul 6 17:39 downloads

downloads -> /storage/emulated/0/Download

cannot open audit interface - aborting

when i install mysql-server, i get error

cannot open audit interface - aborting
addgroup: /usr/sbin/groudadd -g 101 mysql return error code 1. Exiting.
...

Please help!

Support for i386, i686

Thanks for this, it works great!

I had to add a couple if statements for it to with on my Chromebook Pixel 2 (i686). I the Ubuntu architecture that I used was i386. I can make a PR if you'd like but the change is pretty small.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.