apt/apt-get not working with proxychains4
qfooo opened this issue · comments
Hello, this Ubuntu-in-Termux is wonderful. Just wanted to point out some minor issues. I have set up a proxychains4 on my Ubuntu-in-termux to work with a socks5 proxy server. Most commands like wget, git and curl work fine with proxychains4. However installing packages with "proxychains4 apt install [package]" or "proxychains4 apt-get install [package]" is not working. It shows a strange bug trying to connect to port 0 on the repo url rather than port 80. I was able to remedy this issue by installing aptitude. Initially aptitude was also having an issue not wanting to update/upgrade/install throwing an error:
failed to rename /var/lib/aptitude/pkgstates to /var/lib/aptitude/pkgstates.old - save_selection_list (1: Operation not permitted)
What I did here was to create the file /var/lib/aptitude/pkgstates (it was missing).
Running "touch /var/lib/aptitude/pkgstates" did the trick. Then I had a functioning aptitude which surprisingly worked perfectly well with the "proxychains4" command. Thus I am able to install packages through socks proxy with commands like "proxychains4 aptitude install [package]". Just wanted to share this for others that might need to install packages through proxy on their awesome Ubuntu in Termux.
Nice thank you
By the way this issue is ubuntu's and if you want you can report it directly to ubuntu