I've been trying to install Powershell for a few hours now. I run this under root:
apt update && apt -y install powershell
This is what I end up getting after it runs through and seemingly downloads
Package powershell is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'powershell' has no installation candidate
When I try to run this same command outside of root using sudo, I get the following:
E: Could not open lock file /var/lib/dpkg/lock-frontend - open (13: Permission denied)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), are you root?
I have updated everything and tried a few different ways. I even downloaded a completely new Virtual Machine in Parallels to see if restarting would help out. I still run into the same problems. This is a Kali Linux VM on Parallels MacOS M1. Not sure if that matters or not. I think Parallels itself may possibly be using an apt process in the background, but when I do:
sudo killall apt apt-get
I end up getting
apt: no process found
apt-get: no process found
I've been trying everything. I'm on a new Mac so I don't have too many VM options. If someone could figure this out in Parallels, it would be a great help.
I've tried a lot. In the description above.
To install PowerShell in Kali Linux open the terminal and type:
sudo apt update
sudo apt install -y snapd # install daemon and tooling that enable snap packages
sudo systemctl enable --now snapd apparmor
Log out and back in again, and run the following command to install the powershell snap package.
sudo snap install powershell --classic
Related
My current DDEV installation on WSL2 Ubuntu 20.04 LTS is v1.16.7. Since I plan to start using Drupal 10, I need to upgrade -- for example, to 1.21.4. So I issued the commands to upgrade as indicated in the documentation and I get "ddev is already the newest version (1.21.4)", and nothing new is installed, and I still end up having v1.16.7. I tried the full "curl" command and all the normal update commands, but every time it tells me all is well, ddev is already the newest version ... and then I still have the same version as before. I'd like to avoid uninstalling everything, which seems like a drastic solution. Any ideas about what's going on?
You have more than one version of DDEV installed, and you'll have to sort it out. On Linux (WSL2) your $PATH determines where it looks for executable binaries. You can echo $PATH to see what the order is, and you can which ddev to find out which one it's using. (You don't have to do or understand the below once you understand that, but you can continue for more detail.)
On WSL2 you're likely to have
/home/linuxbrew/.linuxbrew/bin/ddev (If you installed with homebrew). That may or may not be in your $PATH; sometimes people don't get it into their $PATH properly.
/usr/local/bin/ddev (If you installed with install_ddev.sh). /usr/local/bin is almost always in the $PATH of a Linux system.
/usr/bin/ddev (If you installed with the newer apt install ddev technique, which is recommended).
All three of these work fine and are supported, but I recommend that you go with the newer apt install technique.
So you can do this:
brew uninstall ddev
sudo rm -f /home/linuxbrew/.linuxbrew/ddev /usr/local/bin/ddev
That will remove the other ones.
Then follow the Linux instructions in the docs and
curl -fsSL https://apt.fury.io/drud/gpg.key | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/ddev.gpg > /dev/null
echo "deb [signed-by=/etc/apt/trusted.gpg.d/ddev.gpg] https://apt.fury.io/drud/ * *" | sudo tee /etc/apt/sources.list.d/ddev.list
sudo apt update && sudo apt install -y ddev
That should get you the ddev in /usr/bin/ddev which will certainly be in your $PATH.
On WSL2 with DDEV v1.21.4, you'll want to install DDEV on the Windows side as well, just for the odd case where you use a non-*.ddev.site hostname, and DDEV needs to update the hosts file on the Windows side. So in admin PowerShell, choco install -y ddev.
Uninstall GitHub Desktop from Ubuntu
How can I remove my github dektop app. It is not working perfectly, so I want to uninstall and re-install it.
Here is the command that produces an error:
sudo apt-get remove GitHub Desktop
sudo apt remove github-desktop
There are 2 ways or i should say 2 commands :
sudo apt remove github-desktop
will remove the binaries, but not the configuration or data files of the package
sudo apt remove --purge github-desktop
will remove about everything regarding the package packagename, [...]
Particularly useful when you want to 'start all over' with an application because you messed up the configuration.
I am following the steps from this website to customize my Ubuntu image. After unpacking the clean .iso I add some files to the "remaster" and also I would like to install some apps (wireshark for example), so when the systems boots with the custom image, there is no need to install anything. I run the following script:
sudo uck-remaster-clean
sudo uck-remaster-unpack-iso my.iso
sudo uck-remaster-unpack-rootfs
// .. add desired files to the remaster
sudo apt-get install wireshark
sudo uck-remaster-pack-rootfs -c
sudo uck-remaster-pack-iso -g myNew.iso
However, wireshark is installed on the machine on which I am running the script, not in the remaster-root system. What do I need to modify to have the apps installed on the unpacked ISO? Is it even possible?
You skipped a step, you need to sudo uck-remaster-chroot-rootfs before.
Now you can install packages with apt-get and perform all kinds of customizations.
I originally followed the guide at http://www.postgresql.org/docs/9.3/static/runtime.html. It instructed me to install postgres-xc, which is meant for making clusters of databases. On other sites, I was instructed to use the postgres-9.3 package (or 9.x) instead of the postgres-xc package. One inconsistency I noticed was that arguments such as --nodename were missing from the original guide, which led me to believe there was an issue with the original guide
I have uninstalled postgres-xc using both apt-get remove --purge postgres-xc and dpkg remove --purge postgres-xc, as advised by others, as well as following this solution, which involves changing postgres-xc.prerm so that it exits early on.
Additionally, I have uninstalled and reinstalled the postgresql-package many times and also run sudo apt-get install postgresql postgresql-contrib and sudo apt-get install postgresql-9.3 postgresql-contrib-9.3. I have done this after uninstalling other version. When I try running the postgres command in Bash, I get the following error:
The program 'postgres' is currently not installed. You can install it by typing:
sudo apt-get install postgres-xc
I've been trying to get this to work for a while, but nothing has worked so far. The only binary for PostgreSQL I can use is psql, which is just a dynamic session for it (and I want to set up a server).
I wants to make my Pi a network security tool, so I downloaded the source code from Raspberry Pwn's github source [https://github.com/pwnieexpress/Raspberry-Pwn].
I found my network rather slow when installing, so I interrupted the progress. I used its uninstall script to make sure that all changes would be recovered.
The uninstall successfully ended, but since then I cannot proceed on to the GUI after I typed startx. Are there any way for me to proceed a clean install of all GUI components?
Thanks
You could try the following:
sudo apt-get remove --purge xserver-xorg
sudo apt-get install xserver-xorg
sudo dpkg-reconfigure xserver-xorg