Debian Stretch update issue - apt

I am trying to keep updated my debian stretch on my laptop.
When i run this command
apt-get update && apt-get upgrade
it shows following output
Reading package lists... Done
E: The repository 'http://ftp.us.debian.org/debian stretch Release' does no longer have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: The repository 'http://ftp.us.debian.org/debian stretch-updates Release' does no longer have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
Here is my sources.list
deb http://ftp.us.debian.org/debian/ stretch main
deb-src http://ftp.us.debian.org/debian/ stretch main
deb http://ftp.us.debian.org/debian/ stretch-updates main contrib
deb-src http://ftp.us.debian.org/debian/ stretch-updates main contrib
deb http://security.debian.org/debian-security stretch/updates main contrib non-free

As stands in the apt-secure manpage:
Starting with version 0.6, APT contains code that does signature checking of the Release file for all repositories.
This means that if apt cannot verify the signatures it wont go on. It will only update if you specify --allow-unauthenticated in apt like this:
sudo apt-get --allow-unauthenticated update

Related

local apt repo update own software

I've created a local apt repo on apache2 using this structure:
mkdir -p /var/www/html/repo/pool/main/
cp /home/xxx.deb /var/www/html/repo/pool/main/.
mkdir -p /var/www/html/repo/dists/focal/main/binary-amd64
cd /var/www/html/repo
dpkg-scanpackages --multiversion --arch amd64 pool/ > dists/focal/main/binary-amd64/Packages
cat dists/focal/main/binary-amd64/Packages | gzip -9 > dists/focal/main/binary-amd64/Packages.gz
Made a release, signed the release in /var/www/html/repo/dists/focal
Added rule in /etc/apt/sources.list.d/gmss.list
After all this I can install my debs on this repository, however when I add a new version of my software in the pool and make a new package file and I do:
apt update
apt install softwarepkg
It says that the latest version is already installed.
How can I get this to update to the latest version op my software?
You may want to try running apt clean to clear the cache, which may have the older version of your package.

Why do I still get "N: See apt-secure(8) manpage for repository creation and user configuration details." weeks after

Few weeks ago I tried to install an IDM replica on Ubuntu 20.04 from Focal. However I got an error and from ever since, whenever I run "Sudo apt update" the same error returns.
Err:17 http://ppa.launchpad.net/noobslab/apps/ubuntu focal Release
404 Not Found [IP: 91.189.95.85 80]
Reading package lists... Done
E: The repository 'http://ppa.launchpad.net/noobslab/apps/ubuntu focal Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
Screenshot of the terminal
sudo apt clean
cd /var/lib/apt
sudo mv lists lists.old
sudo mkdir -p lists/partial
sudo apt update

How can I insert a word inside a command in Linux?

Now, I have a simple file that runs every time I open my Gitpod(cloud env). I am making a file so that I can access it via ngrok. But, I need some packages, like wget, unzip and neofetch(for my ease). But it opens in a different terminal and I have to enter y every time. Is there a way to put y in the command and it will install automatically?
Source code for the file:
#!/bin/bash
sudo apt update
sudo apt install wget unzip openssh-server neofetch -y
sudo service ssh start
echo "Set Password for Gitpod as gitpod"
sudo passwd gitpod
wget "https://bin.equinox.io/c/4VmDzA7iaHb/ngrok-stable-linux-amd64.zip"
unzip "ngrok-stable-linux-amd64.zip"
echo "I need your ngrok auth token. Enter it below."
read -p "ngrok authtoken:" authtoken
./ngrok authtoken $authtoken
echo "Authtoken activated, now activating server..."
./ngrok tcp 22
sudo apt install wget unzip openssh-server neofetch -y
Have I put correctly in this line? If this works, whenever I get a cloud environment, it could just install all deps and go ahead.
Output:
NOT an answer, an output.
The fish shell I like and use's output:
Welcome to fish, the friendly interactive shell
Type `help` for instructions on how to use fish
gitpod#ws-588be66f-373e-46f0-8342-5d39b8c863f4 /w/coder-lg-blog-codedoc (master)> sh .gitpod/ngrok.sh
Hit:1 https://download.docker.com/linux/ubuntu focal InRelease
Hit:2 http://security.ubuntu.com/ubuntu focal-security InRelease
Hit:3 http://archive.ubuntu.com/ubuntu focal InRelease
Hit:4 http://ppa.launchpad.net/git-core/ppa/ubuntu focal InRelease
Hit:5 https://deb.nodesource.com/node_16.x focal InRelease
Hit:6 http://archive.ubuntu.com/ubuntu focal-updates InRelease
Hit:7 https://apt.llvm.org/focal llvm-toolchain-focal InRelease
Hit:8 http://archive.ubuntu.com/ubuntu focal-backports InRelease
Reading package lists... Done
Building dependency tree
Reading state information... Done
107 packages can be upgraded. Run 'apt list --upgradable' to see them.
.gitpod/ngrok.sh: 5: y: not found
WARNING: apt does not have a stable CLI interface. Use with caution in scripts.
Yeah its a cloud Gitpod env for my blog and I want SSH tunneled via ngrok but it says this:
/repo > .gitpod/ngrok.sh: 5: y: not found
How can I fix this? The mod deleted the last output so please don't delete this! It is mainly an output of the Gitpod Terminal.
You can add an echo command in your script and use this as a standard input for your next command.
echo y | [next-command]
Please don't delete.
By #Biffen and this is the solution!
That error doesn’t look like the result of the code in the question. Are you running the strange suggestion in one of the answers; | y? That won’t work. Have a look at this.
Thanks to everyone who helped here, and I am marking this as answer, because Biffen's reply was a comment.
Edit: In 2 days as of now, I can mark this as answer, because, Stack Overflow said so.

Debian (buster) requiring iwlwifi-5000[1-5].ucode

During Debian (buster) installation, I got a message telling me that the files
iwlwifi-5000[1-5].ucode were needed. I first finished installing without the files.
Then, after reading this related page:
https://packages.debian.org/buster/all/firmware-iwlwifi/download
I have added the following line to the file /etc/apt/sources.list
deb http://ftp.debian.org/debian buster main non-free
but when running the command:
aptitude search iwlwifi
I don't get any result.
Did I forget something or did anything the wrong way?
A stupid mistake for those often using aptitude or apt.
I had forgotten to run:
aptitude update
after modifying the file /etc/apt/sources.list
Hoping this will be useful to someone.

Ubuntu 14.04 apt-get dist-upgrade error on bcmwl-kernel-source

A dist-update I just did hung (froze) after printing line:
DKMS: install completed.
I had to close the terminal to kill process, and to carry on did
sudo lsof /var/lib/dpkg/lock
kill -15 THE-PID
sudo dpkg --configure -a
But dist-update and command below (with output) still hangs, freezes on statement:
DKMS: install completed.
$ sudo apt-get install bcmwl-kernel-source
Reading package lists... Done
Building dependency tree
Reading state information... Done
bcmwl-kernel-source is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
3 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
Setting up bcmwl-kernel-source (6.30.223.248+bdcom-0ubuntu0.1) ...
Removing old bcmwl-6.30.223.248+bdcom DKMS files...
-------- Uninstall Beginning --------
Module: bcmwl
Version: 6.30.223.248+bdcom
Kernel: 3.13.0-24-generic (x86_64)
-------------------------------------
Status: Before uninstall, this module version was ACTIVE on this kernel.
wl.ko:
- Uninstallation
- Deleting from: /lib/modules/3.13.0-24-generic/updates/dkms/
- Original module
- No original module was found for this module on this kernel.
- Use the dkms install command to reinstall any previous module version.
depmod....
DKMS: uninstall completed.
------------------------------
Deleting module version: 6.30.223.248+bdcom completely from the DKMS tree.
------------------------------
Done.
Loading new bcmwl-6.30.223.248+bdcom DKMS files...
Building only for 3.13.0-24-generic
Building for architecture x86_64
Building initial module for 3.13.0-24-generic
Done.
wl:
Running module version sanity check.
- Original module
- No original module exists within this kernel
- Installation
- Installing to /lib/modules/3.13.0-24-generic/updates/dkms/
depmod....
DKMS: install completed.
I dont think reboot is right answer here. Might not boot at all!
Gad Zooks! Any tips & tricks?
Probably should have commands below before update/upgrade but only hind sight is 20/20
sudo apt-get autoclean
sudo apt-get autoremove
Thanks,
Brad
It looks like my Broadcomm Wireless drivers do not play well with latest Ubuntu 14.04 updates.
I just removed debian packages bcmwl-kernel-source and dkms.
The packages might very well run fine, but apt-get upgrade hangs, and I don't want to to deal with contantly freezing updates.
Now I can run 'sudo apt-get dist-upgrade' and smooth sailing.

Resources