Debian: How can I pull a single package with dependencies from another repository? - repository

I am on debian etch and I want to pull subversion1.5.1 from testing though it is a production machine. I need to keep the risk minimal.
Any hints?

Just add the testing repository to your sources.list and pin the priority of the testing packages to a very low value:
Add the following to /etc/apt/preferences:
Package: *
Pin: release a=testing
Pin-Priority: 200
200 means that new packages in testing still override local packages that are not in stable (local is always 100), but not ones that are in the stable repo as well.
Read apt_preferences(5) for more information on pinning.
Then, you can install packages from testing by doing
$ apt-get install -t testing $some_package
but they won't be installed by normal upgrade operations or won't be the default when installed with apt.

Related

rpm build with local Required: some_local_package.rpm

Requires: in the spec files sets the package dependencies, but what will happen if the repo of the requirements is not in the repolist?
Is there a way to use pre downloaded rpm files and tell the rpmbuild that the dependencies should be installed from the local file like yum localinstall.
You're conflating rpm and yum when you mention repolist.
rpm is a lower level and only knows about RPM files
yum collects sets of RPMs into repositories and sits on top of RPM to handle dependencies
Now, to answer the question - rpmbuild does not need anything from the Requires field to build the RPM. If it does, then the RPMs should be listed as BuildRequires in the specfile and only be in Requires if the end user needs it to be installed to run the final product. For example, to build you might need foo-devel but at runtime you only need libfoo. Those should be declared appropriately.
Even if you fix the Requires vs. BuildRequires fields, it still won't help you - rpmbuild cannot install RPMs itself because you should never run rpmbuild as root. An error in a specfile can very easily nuke an entire machine if it's run as root.

How do I uninstall NodeSource NSolid from my computer?

I installed NodeSource's NSolid on my computer and it took over my node binary. How do I uninstall it?
NSolid provide an uninstall script. On a Mac, simply run:
sudo /usr/local/nsolid/uninstall
N|Solid replace node binary to ensure that all your apps are getting the additional features of N|Solid. The best way to return to Node.js again is reinstalling it.
N|Solid is shipped with a specific npm version that guarantee total harmony on the ecosystem. Reinstalling Node.js also replace the npm version avoiding issues about version miss matching.
Also you should remove manually the nsolid binary. You can get the installed path running which nsolid

Install Older Version of Mono

Today my Ubuntu updated Mono to 4.2.1.102. It will not allow a certain program I absolutely need to run. How can I down-grade it to 4.0.5.1? I have tried...
sudo apt-get install mono-complete=4.0.5.1
That doesn't work.
Edit your /etc/apt/sources.list.d/mono-xamarin.list and change:
deb http://download.mono-project.com/repo/debian wheezy main
to:
deb http://download.mono-project.com/repo/debian wheezy/snapshots/4.0.5.1 main
That will pin it to version 4.0.5.1.
FYI: Make sure that you do not have any alpha/beta repos for mono in any of your /etc/apt/sources/list.d/xxxxx.list files.
Basic Steps to Downgrade:
sudo apt-get remove mono-complete
# Edit your mono-xamarin.list and pin it to the version of your choice.
sudo apt-get update
sudo apt-get install mono-complete
Accessing older releases If for some reason you want to pin an older
version of Mono rather than updating to the latest, you can modify the
Debian repository to “wheezy/snapshots/X.XX.X” instead of “wheezy”.
For example, “wheezy/snapshots/3.10.0” will lock you to that version.
These snapshots will cease receiving updates as soon as the next major
Mono version gets uploaded - for example, as soon as Mono 3.12 gets
uploaded, 3.10 will never receive updates.
On RPM distributions, force the package version in your package
manager - all older versions are published in the YUM metadata and
should be available.
Ref: http://www.mono-project.com/docs/getting-started/install/linux/#accessing-older-releases
Ref: Versions available:
http://download.mono-project.com/repo/debian/pool/main/m/mono/
If, like me, you followed the official guide: https://www.mono-project.com/download/stable/ then you would have added an apt key and created
/etc/apt/sources.list.d/mono-official-stable.list
You can keep the key, but remove the file above using sudo rm -r /etc/apt/sources.list.d/mono-official-stable.list
Then make sure you follow the best answer above by editing the mono-xamarin.list file for the version you want and remove the version of mono you have.
Then apt update, then install mono-complete. An easy way to know you are correctly downloading and compiling a different version is that apt will prompt you asking if you want to download the files, and the size will be different.
Hope this helps someone, this last step made it work for me.
My system is Ubuntu 18.04.

Fedora 21 packages repo in cobbler not found

I am attempting to install Fedora 21 with additional packages (dhcp, tftp-server, tftp, subversion, vim) using cobbler as my provisioning system over pxeboot.
The problem is that the installation will show an error about packages/groups not existing when it tries to install packages for Fedora, specifically it will pop up an error for all of the packages I try to install in the list below. It seems that the repo information is not right because not a single one of my packages is being installed even though when I check the repo on the web they are present.Here are the relevant sections from my kickstart file.
install
url --url=http://192.168.1.1/cblr/links/Fedora_21_Server-i386/
repo --name="Fedora_21_i386_Server" --baseurl=http://192.168.1.1/cblr/repo_mirror/Fedora_21_i386/
auth --useshadow --passalgo=md5
graphical
firstboot --disable
keyboard us
lang en_US
timezone America/Los_Angeles
selinux --disabled
logging --level=info
reboot
bootloader --location=mbr
zerombr
clearpart --all --initlabel
part swap --fstype="swap" --size=1000
part / --fstype="ext3" --grow --size=1
%packages
#base
#base-x
#editors
#graphical-internet
#system-tools
#admin-tools
#fonts
#lxde-desktop
dhcp
tftp
tftp-server
subversion
vim-enhanced
vsftpd
minicom
%end
I have also tried setting --baseurl as a Fedora mirror (--baseurl=http://mirror.pnl.gov/fedora/linux/releases/21/Server/i386/os/) but that does not work either. I have the above repo added as a cobbler repo and I have linked my Fedora 21 profile to it. One caveat is that I chose "No" for the local mirror option because right now my VM does not have enough space for the Fedora repo.
One solution is to install the packages in a post-install section using standard yum commands. For example,
%post
yum -y install minicom
yum -y install vsftpd
I've used this workaround with F20 installs.

CentOS yum 'No package gnuradio available'

I'm installing GNU Radio and following the instruction here
But everytime I try to do sudo yum install gnuradio, it says
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
* base: centos.mirror.cdnetworks.com
* extras: centos.mirror.cdnetworks.com
* updates: centos.mirror.cdnetworks.com
Setting up Install Process
No package gnuradio available.
Error: Nothing to do
It's a fresh installed CentOS 6.5 and I've never edited CentOS yum repository information. What's wrong with gnuradio? They've removed the package from yum repository?
In their website, they provide several ways to install it including PyBOMBS. But I prefer yum. Building from source is somewhat bothering me so it's the last thing I will try.
By default CentOS does not include all the repositories needed by gnuradio and its dependencies.
You additionally need to configure/add at least RPMForge and Epel for your CentOS.
References:
http://wiki.centos.org/AdditionalResources/Repositories/RPMForge#head-f0c3ecee3dbb407e4eed79a56ec0ae92d1398e01
http://www.rackspace.com/knowledge_center/article/installing-rhel-epel-repo-on-centos-5x-or-6x
This is what I was told, but I have not yet tested this so cannot say is is correct for sure.