Debian: how to uninstall every packages related to a removed package? Posted: 31 Oct 2021 10:24 AM PDT I am doing tests with ZFS on Debian Bullseye 11.1, but this question is very general. In my example with ZFS, the installation is very easy: apt-get install zfsutils-linux zfs-zed zfs-dkms This install a bunch of packages, among them are linux-headers-xxx, gcc, cpp, etc. When I uninstall ZFS I do apt-get autoremove --purge zfsutils-linux zfs-zed zfs-dkms This remove some packages, but lots remain installed although not needed anymore. Among the remaining packages are linux-headers-xxx, gcc, and cpp. I can have the list of packages installed at a certain time (looking into /var/log/apt/history.log or /var/lib/dpkg/info/*.list), but this is time consumming and error prone. --> how can I list/delete the packages automatically installed and no longuer needed? |
How can I have locally installed files be automatically sourced when I log into my account? Posted: 31 Oct 2021 10:12 AM PDT I have built and installed a new piece of software manually (from a remote git repository). Every time I want to use it, I run something like, . /path/to/setup_software.sh but I would like that to happen automatically every time I log into my account, instead of doing it manually. I have tried to put the command above inside my .bashrc file, so that it the setup file is sourced every time I open my kernel. Everything works fine after that and I am happy. My only minor (really minor) problem is that it prints some log messages just after when I open the kernel and the whole sourcing takes some time (which I don't like having :D). Anyways, I am assuming there is a neater solution out there, perhaps moving my installation folder to somewhere that runs the setup file automatically; any help would be greatly appreciated. |
I am stuck in Grub screen after installing Fedora Posted: 31 Oct 2021 10:16 AM PDT After installing Fedora on my laptop, i am stuck in the Grub screen. Here are my disk partitions I tried this grub> set root=(hd0,2) grub> linux /vmlinuz-5.11.12-300.fc34x86 grub> initrd /initramfs-5.11.12-300.fc34.x86_65 grub> boot And got this error Am I using the wrong commands? Could somebody tell me which commands I need to write. Thanks for helping out! |
Why pulseaudio is reported as not running? Posted: 31 Oct 2021 10:20 AM PDT I have Ubuntu 21.10 and I get the below results related to pulseaudio . What should I do to "connect" to pulseaudio such that pacmd list-sinks to correctly report something? $sudo netstat -tlupn | egrep -i "mopidy|pulse" tcp 0 0 0.0.0.0:4713 0.0.0.0:* LISTEN 1730/pulseaudio tcp6 0 0 :::4713 :::* LISTEN 1730/pulseaudio $pacmd list-sinks No PulseAudio daemon running, or not running as session daemon. $ps -ef | egrep "/[p]ulseaudio" lightdm 1730 1668 0 Oct30 ? 00:04:35 /usr/bin/pulseaudio --daemonize=no --log-target=journal UPDATE $systemctl --user --no-pager status pulseaudio ● pulseaudio.service - Sound Service Loaded: loaded (/usr/lib/systemd/user/pulseaudio.service; enabled; vendor preset: enabled) Active: active (running) since Sun 2021-10-31 19:15:19 EET; 3min 27s ago TriggeredBy: ● pulseaudio.socket Main PID: 1992370 (pulseaudio) Tasks: 2 (limit: 37152) Memory: 1.7M CPU: 23ms CGroup: /user.slice/user-1000.slice/user@1000.service/session.slice/pulseaudio.service └─1992370 /usr/bin/pulseaudio --daemonize=no --log-target=journal Oct 31 19:15:18 adrhc.go.ro systemd[1510]: Starting Sound Service... Oct 31 19:15:19 adrhc.go.ro systemd[1510]: Started Sound Service. $systemctl --user --no-pager status pipewire ● pipewire.service - Multimedia Service Loaded: loaded (/usr/lib/systemd/user/pipewire.service; enabled; vendor preset: enabled) Active: active (running) since Sat 2021-10-30 23:39:22 EEST; 20h ago TriggeredBy: ● pipewire.socket Main PID: 1767 (pipewire) Tasks: 2 (limit: 37152) Memory: 1.4M CPU: 139ms CGroup: /user.slice/user-1000.slice/user@1000.service/session.slice/pipewire.service └─1767 /usr/bin/pipewire Oct 30 23:39:22 adrhc.go.ro systemd[1510]: Started Multimedia Service. Oct 30 23:39:22 adrhc.go.ro pipewire[1767]: RTKit error: org.freedesktop.DBus.Error.AccessDenied Oct 30 23:39:22 adrhc.go.ro pipewire[1767]: could not set nice-level to -11: Permission denied Oct 30 23:39:23 adrhc.go.ro pipewire[1767]: RTKit error: org.freedesktop.DBus.Error.AccessDenied Oct 30 23:39:23 adrhc.go.ro pipewire[1767]: could not make thread realtime: Permission denied |
Issue with httpd and mod_ssl updates rhel Posted: 31 Oct 2021 08:22 AM PDT I have a RHEL 7 server running with httpd. While applying recent security patches downloaded through repotrack, seeing an error attached here. The actual package needs to be updated is mod_ssl, but which has dependency on httpd. But when all this is being downloaded and applied, there is an inbuilt module erorr is thrown out of httpd. Is anyone aware of this issue? Maybe Uninstalling and re-installing the latest may fix the problem, but I had to deliver this as an update package. |
Why ppp0 is reported as both connected and disconnected? Posted: 31 Oct 2021 07:57 AM PDT I have an Ubuntu 21.10 and I get the below confusing network status related to ppp0; RDS (aka StamAcasa.rdsne ) is the name of my network connection providing access to Internet. Why ppp0 is reported as disconnected by nmcli device but connected by ifconfig ? How should I fix this? $nmcli device DEVICE TYPE STATE CONNECTION eno1 ethernet connected RDS enp2s0 ethernet connected enp2s0 br-4d725814c237 bridge connected br-4d725814c237 br-667e68774f98 bridge connected (externally) br-667e68774f98 docker0 bridge connected (externally) docker0 ppp0 ppp disconnected -- lo loopback unmanaged -- $nmcli device show ppp0 GENERAL.DEVICE: ppp0 GENERAL.TYPE: ppp GENERAL.HWADDR: (unknown) GENERAL.MTU: 1492 GENERAL.STATE: 30 (disconnected) GENERAL.CONNECTION: -- GENERAL.CON-PATH: -- $ip link show | grep -i ppp 5: ppp0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1492 qdisc fq_codel state UNKNOWN mode DEFAULT group default qlen 3 link/ppp $ifconfig | grep -A5 ppp ppp0: flags=4305<UP,POINTOPOINT,RUNNING,NOARP,MULTICAST> mtu 1492 inet 86.124.169.167 netmask 255.255.255.255 destination 10.0.0.1 ppp txqueuelen 3 (Point-to-Point Protocol) RX packets 64158 bytes 57421437 (57.4 MB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 33280 bytes 13396662 (13.3 MB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 $netstat -r Kernel IP routing table Destination Gateway Genmask Flags MSS Window irtt Iface default StamAcasa.rdsne 0.0.0.0 UG 0 0 0 ppp0 StamAcasa.rdsne 0.0.0.0 255.255.255.255 UH 0 0 0 ppp0 link-local 0.0.0.0 255.255.0.0 U 0 0 0 enp2s0 172.17.0.0 0.0.0.0 255.255.0.0 U 0 0 0 docker0 172.20.0.0 0.0.0.0 255.255.0.0 U 0 0 0 br-4d725814c237 172.29.0.0 0.0.0.0 255.255.0.0 U 0 0 0 br-667e68774f98 192.168.0.0 0.0.0.0 255.255.255.0 U 0 0 0 enp2s0 192.168.0.0 0.0.0.0 255.255.255.0 U 0 0 0 enp2s0 192.168.31.0 0.0.0.0 255.255.255.0 U 0 0 0 enp2s0 $ping www.google.com PING www.google.com (172.217.19.100) 56(84) bytes of data. 64 bytes from bud02s27-in-f4.1e100.net (172.217.19.100): icmp_seq=1 ttl=59 time=33.3 ms 64 bytes from muc03s07-in-f100.1e100.net (172.217.19.100): icmp_seq=2 ttl=59 time=33.5 ms $lspci | grep -i eth 00:1f.6 Ethernet controller: Intel Corporation Ethernet Connection (7) I219-V (rev 10) 02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 15) |
Display users who logged in, who logged out Posted: 31 Oct 2021 09:07 AM PDT My task: Write a program that outputs information about users in the system after a certain time interval: who entered, who left. I tried to do it differently by comparing two files. I don't know how well I do it. comm is not very good here, I know. I tried using diff , but her output to the console is incomprehensible to me, and when I tried diff -q , I got only this line Files 1.txt and 2.txt differ Please help me. #!/bin/bash while (true) do who > 1.txt sleep 10s who > 2.txt (comm -13 1.txt 2.txt) > 3.txt (comm -23 2.txt 1.txt) > 4.txt echo IN : cat 3.txt echo OUT : sleep 10s cat 4.txt echo [______________________________________________________________] done upd: or better like this..idk #!/bin/bash while (true) do who > 1.txt sleep 10s who > 2.txt (comm -13 1.txt 2.txt) > 3.txt echo IN : cat 3.txt echo OUT : sleep 10s who > 2.txt (comm -23 3.txt 2.txt) > 4.txt cat 4.txt echo [______________________________________________________________] done |
Infer windows 7/8/10 ISOs official URLs from Linux Posted: 31 Oct 2021 08:31 AM PDT How to infer windows 7/8/10 ISOs official URLs from Linux and download them ? I only have Linux on my system and hence cannot run the Windows ISO downloader to do so. How can I do it ? |
Samba share folder name incorrectly displayed on linux machine Posted: 31 Oct 2021 08:07 AM PDT I have a NAS server running OMV 5 which I use to store personal data (documents, photos, videos, etc.). I use Samba to share the data from the NAS and I am running Fedora 33 on the client that I use to access the shared data. The issue that I have is that folders named aux on the NAS appear as AHY9U3~9 on the Fedora client, see example below The working directory in the left tmux panel is on the client whereas in the right panel the working directory is on the NAS. I find it bizarre that I can access the folder on the client using either the weird name or the correct name the folder has on the NAS. I stumbled upon this "error" when I was trying to synchronize data between the client and the NAS using software run on the client. I have a bunch of folders named aux scattered throughout the folder hierarchy and the sync software flagged a difference for them when the issue is actually how their names are mapped on the client. I don't know what causes the issue and, most importantly, how to fix it. I am also wondering if there are other folder names that are erroneously mapped on the client side. Please find below software version information for both the client and the server Server samba version: Samba version 4.9.5-Debian Client samba version: Version 4.13.12 Client info: - Kernel version - 5.14.13-100.fc33.x86_64
- Cinnamon version - 4.8.6
I found some related posts, see below, however, I would reckon that aux is a valid filename according to samba rules, isn't it? - samba how to display files with colon in their names?
- Not mangling names renders music unplayable on Windows 10 Samba
EDIT: Below is the global section and the respective share section from smb.conf, [global] workgroup = WORKGROUP server string = %h server dns proxy = no log level = 0 log file = /var/log/samba/log.%m max log size = 1000 logging = syslog panic action = /usr/share/samba/panic-action %d encrypt passwords = true passdb backend = tdbsam obey pam restrictions = no unix password sync = no passwd program = /usr/bin/passwd %u passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* . pam password change = yes socket options = TCP_NODELAY IPTOS_LOWDELAY guest account = nobody load printers = no disable spoolss = yes printing = bsd printcap name = /dev/null unix extensions = yes wide links = no create mask = 0777 directory mask = 0777 use sendfile = yes aio read size = 16384 aio write size = 16384 time server = no wins support = no multicast dns register = no # Special configuration for Apple's Time Machine fruit:aapl = yes [test] path = hidden-path/test/ guest ok = no guest only = no read only = no browseable = yes inherit acls = yes inherit permissions = no ea support = no store dos attributes = no vfs objects = printable = no create mask = 0664 force create mode = 0664 directory mask = 0775 force directory mode = 0775 hide special files = yes follow symlinks = yes hide dot files = yes valid users = invalid users = read list = write list = EDIT2: I wouldn't have thought aux to be a reserved word, but yes, it is, see https://docs.microsoft.com/en-us/windows/win32/fileio/naming-a-file. Thanks to @Ricky for pointing it out. Now, I just need to change the name of my folders. |
Make systemd service inherit environment variables from /etc/profile.d Posted: 31 Oct 2021 08:18 AM PDT I have a systemd service running under a specific user. I erroneously assumed that the service would have access to the environment variables all users inherit from scripts/exports under /etc/profile.d Is there a way to accomplish this without having to manually copy the variables in systemd unit file definition. For example, I have the following $ cat /etc/profile.d/somexports export VAR1=VALUE1 export VAR2=VALUE2 Can this be passed / exported to a systemd service? |
Bash shell: How to assign a bc calculated result to a variable and print it out? Posted: 31 Oct 2021 09:26 AM PDT I'm trying to replicate the code from here For whatever reason, it doesn't work on my computer. The outout, rather than the numercal value, is the command itself. apple$ x='echo "var=500;var%=7;var"|bc' apple$ $x "var=500;var%=7;var"|bc I would like to know why is that. What I did wrong? |
GRUB loader won't start in secure boot Posted: 31 Oct 2021 06:41 AM PDT I have a dual boot setup. I am using Kali Linux and Windows 10. They were working fine until I forgot to shut down my system and Kali went into hibernation. After that PC shutdown-ed because of low power and now I am unable to boot into GRUB loader without disabling secure boot. How can I fix it? Also, I saw a message that CMOS has been reset. |
Bash script to manipulate a csv file Posted: 31 Oct 2021 09:42 AM PDT I have the following csv file: "V1","V2","V3","V4","V5","V6","V7","V8","V9","V10","Class" 65,Female,0.7,0.1,187,16,18,6.8,3.3,0.9,1 62,Male,10.9,5.5,699,64,100,7.5,3.2,0.74,1 62,Male,7.3,4.1,490,60,68,7,3.3,0.89,1 58,Male,1,0.4,182,14,20,6.8,3.4,1,1 72,Male,3.9,2,195,27,59,7.3,2.4,0.4,1 46,Male,1.8,0.7,208,19,14,7.6,4.4,1.3,1 I am only interested in the columns V1:age, V2:sex, V8:grade1, V9:grade2. I would like to create a bash script that will output the the data where V9 is equal to 3 and sort the output by sex, showing the Female data first. I am a 100% beginner with bash scripts and although I know how to obtain this output from shell, I could only come up with this when it comes to bash script commands: #!/usr/bin/env bash INPUT=./phpOJxGL9.csv OLDIFS=$IFS IFS=',' [ ! -f $INPUT ] && { echo "$INPUT file not found"; exit 99; } echo Grade2 = 3 echo Age Sex Grade2 Grade1 echo '************************' while read V1 V2 V3 V4 V5 V6 V7 V8 V9 V10 do if [ $V9 -eg "3" ]; then cut -d',' -f1,2,8,9 | sort -k2 -t',' fi done < $INPUT IFS=$OLDIFS The out put should look somewhat like this: Can anyone help? |
How use du command for root and nested content to get the same total value? Posted: 31 Oct 2021 09:51 AM PDT About the du command with the option -sch If is executed du -sch spring-security appears: 103M spring-security 103M total But if is executed du -sch spring-security/* appears (see the bottom) 12K spring-security/CONTRIBUTING.adoc 12K spring-security/LICENSE.txt 4.0K spring-security/README.adoc 8.0K spring-security/RELEASE.adoc 705K spring-security/acl 17K spring-security/aspects 1.0K spring-security/bom 8.0K spring-security/build.gradle 2.6M spring-security/buildSrc 269K spring-security/cas 4.0K spring-security/class_mapping_from_2.0.x.txt 11M spring-security/config 3.1M spring-security/core 473K spring-security/crypto 13K spring-security/data 4.0K spring-security/dependencies 4.6M spring-security/docs 1.2M spring-security/etc 61K spring-security/gradle 1.0K spring-security/gradle.properties 8.0K spring-security/gradlew 4.0K spring-security/gradlew.bat 304K spring-security/itest 661K spring-security/ldap 1.0K spring-security/local-antora-playbook.yml 265K spring-security/messaging 4.0K spring-security/notice.txt 4.7M spring-security/oauth2 125K spring-security/openid 93K spring-security/remoting 268K spring-security/rsocket 1.2M spring-security/saml2 4.0K spring-security/scripts 4.0K spring-security/settings.gradle 137K spring-security/taglibs 731K spring-security/test 4.2M spring-security/web 36M total What is confuse is: - Why appears for the second command execution 36M and not again 103M?
I tried just in case with du -ch --max-depth=15 spring-security/* but again appears the 36M How get the same total how the first scenario for the second scenario? |
Use custom test function in bash conditional statement Posted: 31 Oct 2021 08:59 AM PDT I have a bash function called numeric that returns either 1 or 0 . numeric () { # compute k either 1 or 0 echo "$k" } How can I use this function in a conditional statement to check if a variable var is numeric? |
How to install R 4.0.* on Raspbian GNU/Linux 10 (buster)? Posted: 31 Oct 2021 09:21 AM PDT I believe I have followed the instructions on the relevant CRAN site to update R to the newest version (currently R 4.0.5) but with no luck. I'm running $ cat /etc/os-release PRETTY_NAME="Raspbian GNU/Linux 10 (buster)" with R version $ R --version R version 3.5.2 (2018-12-20) -- "Eggshell Igloo" What I did is, first add repository to /etc/apt/sources.list http://cloud.r-project.org/bin/linux/debian buster-cran40/ which currently looks like this: deb http://raspbian.raspberrypi.org/raspbian/ buster main contrib non-free rpi # Uncomment line below then 'apt-get update' to enable 'apt-get source' #deb-src http://raspbian.raspberrypi.org/raspbian/ buster main contrib non-free rpi deb http://cloud.r-project.org/bin/linux/debian buster-cran40/ Second, to fetch and import the current signing key: $ sudo apt-key adv --keyserver keys.gnupg.net --recv-key 'E19F5F87128899B192B1A2C2AD5F960A256A04AF' Third, $ sudo apt update $ sudo apt upgrade Now I attempted to install, but that fails. $ sudo apt-get install r-base r-base-dev Reading package lists... Done Building dependency tree Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation: The following packages have unmet dependencies: r-base : Depends: r-base-core (>= 4.0.5-1~bustercran.0) but 3.5.2-1 is to be installed Depends: r-recommended (= 4.0.5-1~bustercran.0) but it is not going to be installed Recommends: r-base-html but it is not going to be installed r-base-dev : Depends: r-base-core (>= 4.0.5-1~bustercran.0) but 3.5.2-1 is to be installed E: Unable to correct problems, you have held broken packages. To solve the issue I tried several things like fixing dependencies issue, $ sudo apt-get autoremove re-installing r-base-core , $ sudo apt update $ sudo apt remove r-base-core $ sudo apt install r-base-core and using the command at the CRAN site mentioned above. $ sudo apt install -t buster-cran40 r-base But I still have R version 3.5.2, i.e. I always get R 3.5.2 instead of R 4.0.5. How do I get R 4.0.5 onto my Raspberry pi? Edit More infos: $ apt search r-base-core Sorting... Done Full Text Search... Done pandoc/stable 2.2.1-3+b2 armhf general markup converter r-base/buster-cran40 4.0.5-1~bustercran.0 all GNU R statistical computation and graphics system r-base-core/stable,now 3.5.2-1 armhf [installed] GNU R core of statistical computation and graphics system r-base-core-dbg/stable 3.5.2-1 armhf GNU R debug symbols for statistical comp. language and environment r-cran-date/stable 1.2.38-1+b1 armhf GNU R package for date handling |
Cannot complete upgrade of Debian Buster to Bullseye [duplicate] Posted: 31 Oct 2021 09:43 AM PDT So, it has been 17 months since Buster release (and setting Bullseye as testing) and I still cannot complete the Buster to Bullseye upgrade. It's not the first time I am upgrading Debian, but this time it overwhelmed me. My first try happened in summer this year, but I surrendered. I managed to upgrade some of the packages, but most of them (over a thousand) remained not upgraded. You can see my earlier "findings" here: https://unix.stackexchange.com/a/596078/447111 I tried today, but failed again. Currently # apt-get dist-upgrade results in: 1013 upgraded, 380 newly installed, 129 to remove, 8 not upgraded. The 129 packages to be removed include kde-runtime (and some other KDE-related), nvidia-driver (and related), python and a lot of lib packages, which is unacceptable. I have searched the web again and the problem seems to be quite common, yet there are no official fixes or workarounds. Some people say remove gcc-8 (https://prodevsblog.com/questions/690521/full-upgrade-to-debian-testing-fails-due-to-libc6-dev-breaks-libgcc-8-dev/), others say install gcc-8-base (https://www.reddit.com/r/debian/comments/h878ci/fullupgrade_to_debian_testing_fails_due_to/) etc., but none worked for me. One guy says that the problem is related to gcc-10 and renaming some of the packages. But I seem to have the *-s1 packages installed already, hence the problem might be somewhere else? Anyway, I am not skilled or persistent enough to dig deeper into this kind of stuff (tracking renamed packages) on my own. I have no idea what the real problem is. Maybe there are many reasons or the complexity depends on which packages one has installed in their system. I have lost any hope and the only solution I see is to format the system partition and install a fresh bullseye or wait until it becomes stable and hope the devs will fix the issue by then. Unless somebody here helps me, please. :) Maybe this will help you find the solution: # dpkg -l gcc-* libc*dev libgcc* ii gcc-10-base:amd64 10.2.1-1 amd64 GCC, the GNU Compiler Collection (base package) ii gcc-10-base:i386 10.2.1-1 i386 GCC, the GNU Compiler Collection (base package) un gcc-4.3 <none> <none> (no description available) un gcc-4.4 <none> <none> (no description available) un gcc-4.5 <none> <none> (no description available) un gcc-4.6 <none> <none> (no description available) ii gcc-8-base:amd64 8.3.0-6 amd64 GCC, the GNU Compiler Collection (base package) ii gcc-9 9.3.0-19 amd64 GNU C compiler ii gcc-9-base:amd64 9.3.0-19 amd64 GCC, the GNU Compiler Collection (base package) un gcc-9-doc <none> <none> (no description available) un gcc-9-locales <none> <none> (no description available) un gcc-9-multilib <none> <none> (no description available) un gcc-doc <none> <none> (no description available) un gcc-multilib <none> <none> (no description available) un gcc-x86-64-linux-gnu <none> <none> (no description available) ii gcc-10-base:amd64 10.2.1-1 amd64 GCC, the GNU Compiler Collection (base package) ii gcc-10-base:i386 10.2.1-1 i386 GCC, the GNU Compiler Collection (base package) ii gcc-8-base:amd64 8.3.0-6 amd64 GCC, the GNU Compiler Collection (base package) ii gcc-9-base:amd64 9.3.0-19 amd64 GCC, the GNU Compiler Collection (base package) un libc-dev <none> <none> (no description available) un libc0.1-dev <none> <none> (no description available) un libc0.3-dev <none> <none> (no description available) ii libc6-dev:amd64 2.28-10 amd64 GNU C Library: Development Libraries and Header Files un libc6.1-dev <none> <none> (no description available) un libcurl4-gnutls-dev <none> <none> (no description available) ii libgcc-9-dev:amd64 9.3.0-19 amd64 GCC support library (development files) ii libgcc-s1:amd64 10.2.1-1 amd64 GCC support library ii libgcc-s1:i386 10.2.1-1 i386 GCC support library un libgcc1 <none> <none> (no description available) un libgccjit-9-dev <none> <none> (no description available) EDIT (October 31, 2021) Bullseye has been released as stable version, but I still cannot upgrade to it. During the last year I haven't really tried to solve it, but running apt-get upgrade from time to time allowed me to upgrade some (few) packages, probably those unaffected by the issue. Here is the updated list of currently installed gcc-related packages: ii gcc-10-base:amd64 10.2.1-6 amd64 GCC, the GNU Compiler Collection (base package) ii gcc-10-base:i386 10.2.1-6 i386 GCC, the GNU Compiler Collection (base package) un gcc-4.3 <none> <none> (no description available) un gcc-4.4 <none> <none> (no description available) un gcc-4.5 <none> <none> (no description available) un gcc-4.6 <none> <none> (no description available) ii gcc-8-base:amd64 8.3.0-6 amd64 GCC, the GNU Compiler Collection (base package) ii gcc-9 9.3.0-22 amd64 GNU C compiler ii gcc-9-base:amd64 9.3.0-22 amd64 GCC, the GNU Compiler Collection (base package) un gcc-9-doc <none> <none> (no description available) un gcc-9-locales <none> <none> (no description available) un gcc-9-multilib <none> <none> (no description available) un gcc-doc <none> <none> (no description available) un gcc-multilib <none> <none> (no description available) un gcc-x86-64-linux-gnu <none> <none> (no description available) un libc-dev <none> <none> (no description available) un libc0.1-dev <none> <none> (no description available) un libc0.3-dev <none> <none> (no description available) ii libc6-dev:amd64 2.28-10 amd64 GNU C Library: Development Libraries and Header Files un libc6.1-dev <none> <none> (no description available) un libcurl4-gnutls-dev <none> <none> (no description available) ii libgcc-9-dev:amd64 9.3.0-22 amd64 GCC support library (development files) ii libgcc-s1:amd64 10.2.1-6 amd64 GCC support library ii libgcc-s1:i386 10.2.1-6 i386 GCC support library ii libgcc1:amd64 1:10.1.0+rp2 amd64 GCC support library (transitional package) un libgccjit-9-dev <none> <none> (no description available) And the output of dist-upgrade attempt: # apt-get dist-upgrade Reading package lists... Building dependency tree... Reading state information.. Calculating update... The following packages were automatically installed and are no longer required: cracklib-runtime enchant fonts-dejavu fonts-linuxlibertine fonts-sil-gentium fonts-sil-gentium-basic freepats g++-9 gstreamer1.0-alsa gstreamer1.0-pulseaudio icoutils kate-data kde-runtime-data kde-style-qtcurve-qt5 kdelibs5-data libbctoolbox1 libboost-atomic1.67.0 libboost-chrono1.67.0 libboost-date-time1.67.0 libboost-filesystem1.67.0 libboost-iostreams1.67.0 libboost-locale1.67.0 libboost-system1.67.0 libboost-thread1.67.0 libbrlapi0.6 libbsh-java libbzrtp0 libcfitsio7 libcrack2 libcroco3 libdlrestrictions1 libdouble-conversion1 libdrm-dev libegl-nvidia-legacy-390xx0:i386 libegl-nvidia0:i386 libegl1-nvidia libegl1-nvidia-legacy-390xx:i386 libenchant1c2a libevent-2.1-6 libexiv2-14 libfaac0 libffi6:i386 libflite1 libfluidsynth1 libgadu3 libgit2-27 libgles-nvidia-legacy-390xx1:i386 libgles-nvidia-legacy-390xx2:i386 libgles-nvidia1 libgles-nvidia1:i386 libgles-nvidia2 libgles-nvidia2:i386 libgles2-mesa-dev libglvnd-core-dev libglx-nvidia-legacy-390xx0:i386 libglx-nvidia0 libglx-nvidia0:i386 libgpgme++2v5 libgps23 libgrantlee-textdocument5 libgraphene-1.0-0 libgssdp-1.0-3 libgssdp-1.2-0 libgstreamer-plugins-bad1.0-0 libgupnp-1.0-4 libgupnp-1.2-0 libgupnp-igd-1.0-4 libhogweed5 libhogweed5:i386 libhttp-parser2.8 libice6:i386 libicu63 libicu63:i386 libigdgmm5 libigdgmm5:i386 libilmbase23 libisl22 libjim0.77 libjson-c4 libjsoncpp1 libkaccounts1 libkdecorations2private6 libkf5emoticons-bin libkf5emoticons-data libkf5emoticons5 libkf5jsembed-data libkf5jsembed5 libkf5libkdepimakonadi5 libkf5xmlrpcclient-data libkf5xmlrpcclient5 libkwineffects11 libkwinglutils11 libkwinxrenderutils11 liblept5 liblilv-0-0 libllvm7 libllvm7:i386 liblouis17 liblouisutdml8 liblrdf0 libmeanwhile1 libmjpegutils-2.1-0 libmms0 libmpdec2 libmpeg2encpp-2.1-0 libmplex2-2.1-0 libmypaint-1.3-0 libnettle7 libnettle7:i386 libnice10 libntrack0 libnvidia-eglcore:i386 libnvidia-glcore:i386 libnvidia-glvkspirv libnvidia-glvkspirv:i386 libnvidia-legacy-390xx-cfg1:i386 libnvidia-legacy-390xx-eglcore:i386 libnvidia-legacy-390xx-glcore:i386 libofa0 libokular5core8 libopenexr23 liborcus-0.14-0 libotr5 libperl5.28 libplymouth4 libpoppler82 libpotrace0 libpwquality-common libpwquality1 libpython2-stdlib libpython2.7 libpython3.7 libpython3.7-minimal libpython3.7-stdlib libqhull7 libqpdf21 libqtcurve-utils2 libraw19 libre2-5 libreadline5 libreadline7 libreoffice libreoffice-avmedia-backend-gstreamer libreoffice-kde5 libreoffice-librelogo libreoffice-nlpsolver libreoffice-script-provider-bsh libreoffice-script-provider-js libreoffice-script-provider-python libreoffice-wiki-publisher librubberband2 libruby2.5 libsane libsbc1 libserd-0-0 libsisu-guice-java libsisu-ioc-java libsm6:i386 libsnmp30 libsord-0-0 libsoundtouch1 libspandsp2 libsratom-0-0 libsrtp2-1 libssh-gcrypt-4 libstdc++-9-dev libtesseract4 libtexlua52 libtidy5deb1 libtss2-udev libturbojpeg0 libu2f-udev libusbmuxd4 libutempter0 libvidstab1.1 libvo-aacenc0 libvpx5 libwildmidi-config libwildmidi2 libx11-xcb-dev libx265-165 libxcb-dri2-0-dev libxcb-dri3-dev libxcb-glx0-dev libxcb-present-dev libxcb-randr0-dev libxcb-render0-dev libxcb-shape0-dev libxcb-sync-dev libxcb-util0 libxcb-xfixes0-dev libxdamage-dev libxshmfence-dev libxtst6:i386 libzbar0 libzimg2 mesa-common-dev ntrack-module-libnl-0 nvidia-driver-bin oxygen-icon-theme perl-modules-5.28 phonon-backend-gstreamer-common polkit-kde-1 printer-driver-hpijs python2 python2-minimal python3-sip python3.7-minimal qml-module-qtquick-controls-styles-breeze qtcore4-l10n ruby-did-you-mean Use 'apt autoremove' to remove them. The following packages will be REMOVED: ffmpeg gstreamer1.0-plugins-bad kaccessible katepart kde-l10n-pl kde-runtime kde-style-breeze-qt4 kde-style-qtcurve-qt4 kdelibs-bin kdelibs5-plugins kdoctools kopete libattica0.4 libavdevice58 libavfilter7 libdbusmenu-qt2 libegl1-nvidia:i386 libgl1-nvidia-glx libgl1-nvidia-glx:i386 libgl1-nvidia-legacy-390xx-glx:i386 libgnustep-base1.26 libhfstospell10 libkabc4 libkactivities6 libkatepartinterfaces4 libkcmutils4 libkde3support4 libkdeclarative5 libkdecore5 libkdesu5 libkdeui5 libkdewebkit5 libkdnssd4 libkemoticons4 libkf5followupreminder5 libkf5kdepimdbusinterfaces5 libkf5sendlater5 libkfile4 libkhtml5 libkio5 libkjsapi4 libkjsembed4 libkldap4 libkmediaplayer4 libkmime4 libknewstuff2-4 libknewstuff3-4 libknotifyconfig4 libkntlm4 libkopete4 libkparts4 libkpimidentities4 libkpimkdav-data libkpimkdav5abi2 libkpimtextedit4 libkpimutils4 libkpty4 libkresources4 libkrosscore4 libksgrd7 libksignalplotter7 libktexteditor4 libldb1 libmediastreamer-base10 libmediastreamer-voip10 libnode64 libntrack-qt4-1 libortp13 libphonon4 libplasma3 libpolkit-backend-1-0 libpolkit-qt-1-1 libprocesscore7 libprocessui7 libpython-stdlib libqca2 libqca2-plugins libqimageblitz4 libqjson0 libqt4-dbus libqt4-declarative libqt4-designer libqt4-network libqt4-opengl libqt4-qt3support libqt4-script libqt4-sql libqt4-sql-mysql libqt4-sql-sqlite libqt4-svg libqt4-xml libqt4-xmlpatterns libqtcore4 libqtdbus4 libqtgui4 libqtwebkit4 libreoffice-style-tango libsolid4 libtaskmanager6 libthreadweaver4 libtss2-esys0 mariadb-client-core-10.3 mariadb-server-core-10.3 nvidia-driver nvidia-driver-libs-nonglvnd nvidia-driver-libs-nonglvnd:i386 nvidia-driver-libs-nonglvnd-i386:i386 nvidia-legacy-390xx-driver-libs-nonglvnd:i386 nvidia-legacy-390xx-nonglvnd-vulkan-icd:i386 nvidia-nonglvnd-vulkan-common nvidia-nonglvnd-vulkan-icd nvidia-nonglvnd-vulkan-icd:i386 phonon phonon-backend-gstreamer plasma-scriptengine-javascript python python-minimal python-parted python-talloc python3.7 qdbus qt-at-spi ruby2.5 sni-qt uno-libs3 user-manager The following NEW packages will be installed: alsa-topology-conf alsa-ucm-conf apt-config-icons-hidpi apt-config-icons-large-hidpi bup bup-doc cpp-10 dctrl-tools dvisvgm enchant-2 fonts-urw-base35 g++-10 gcc-10 gir1.2-gtksource-3.0 glib-networking:i386 gstreamer1.0-plugins-good:i386 gstreamer1.0-plugins-ugly gstreamer1.0-x:i386 hwdata ibus-data isolinux kmailtransport-akonadi kontrast kpeople-vcard kup-backup kuserfeedback-doc libaa1:i386 libabsl20200923 libaom3 libasan6 libatopology2 libavc1394-0:i386 libavif9 libboost-filesystem1.74.0 libboost-iostreams1.74.0 libboost-locale1.74.0 libboost-regex1.74.0 libboost-thread1.74.0 libbpf0 libbrlapi0.8 libbrotli-dev libbrotli1:i386 libbz2-1.0:i386 libc-devtools libcaca0:i386 libcairo-gobject2:i386 libcfitsio9 libclone-perl libcrypt-dev libcrypt1:i386 libcuda1 libcuda1:i386 libcurl3-gnutls:i386 libcurl4:i386 libdatrie1:i386 libdav1d4 libdav1d5 libdebuginfod1 libdeflate0 libdeflate0:i386 libdouble-conversion3 libdv4:i386 libdvdread8 libdw1:i386 libegl-mesa0:i386 libegl-nvidia-tesla-450-0 libegl-nvidia-tesla-450-0:i386 libegl1:i386 libenchant-2-2 libevent-2.1-7 libexiv2-27 libfaudio0 libfaudio0:i386 libfontbox-java libfontconfig-dev libfreetype-dev libfribidi0:i386 libgav1-0 libgbm1:i386 libgcc-10-dev libgdbm-compat4:i386 libgdbm6:i386 libgdk-pixbuf-2.0-0 libgdk-pixbuf-2.0-0:i386 libgdk-pixbuf-xlib-2.0-0 libgit2-1.1 libgl1-nvidia-tesla-450-glvnd-glx libgl1-nvidia-tesla-450-glvnd-glx:i386 libgles-nvidia-tesla-450-1 libgles-nvidia-tesla-450-1:i386 libgles-nvidia-tesla-450-2 libgles-nvidia-tesla-450-2:i386 libglx-nvidia-tesla-450-0 libglx-nvidia-tesla-450-0:i386 libgnustep-base1.27 libgps28 libgraphite2-3:i386 libgsettings-qt1 libgssdp-1.2-0 libgtksourceview-3.0-1 libgtksourceview-3.0-common libgudev-1.0-0:i386 libgupnp-1.2-0 libharfbuzz0b:i386 libhfstospell11 libhogweed6:i386 libhttp-parser2.9 libicu67 libicu67:i386 libiec61883-0:i386 libieee1284-3:i386 libigdgmm11 libigdgmm11:i386 libilbc3 libilmbase25 libip4tc2 libip6tc2 libjim0.79 libjs-highlight.js libjson-c5 libjuh-java libjurt-java libkaccounts2 libkcolorpicker0 libkdecorations2private7 libkdsoap1 libkf5authcore5 libkf5dav-data libkf5dav5 libkf5kdegames7 libkf5pulseaudioqt2 libkimageannotator-common libkimageannotator0 libkpmcore10 libksgrd9 libksignalplotter9 libksysguardformatter1 libksysguardsensorfaces1 libksysguardsensors1 libkuserfeedbackcore1 libkuserfeedbackwidgets1 libkwaylandserver5 libkwineffects12a libkwinglutils12 libkwinxrenderutils12 libldb2 liblibreoffice-java libllvm11 libllvm11:i386 liblouis20 liblouisutdml9 libmarkdown2 libmd0 libmd0:i386 libmd4c0 libmpdec3 libmypaint-1.5-1 libncursesw6:i386 libnettle8:i386 libnghttp2-14:i386 libnode72 libnotificationmanager1 libnsl-dev libnsl2 libnsl2:i386 libnspr4:i386 libnss-nis libnss-nis:i386 libnss-nisplus libnss-nisplus:i386 libnss3:i386 libnvidia-ptxjitcompiler1 libnvidia-ptxjitcompiler1:i386 libnvidia-tesla-450-cbl libnvidia-tesla-450-cfg1 libnvidia-tesla-450-cuda1 libnvidia-tesla-450-cuda1:i386 libnvidia-tesla-450-eglcore libnvidia-tesla-450-eglcore:i386 libnvidia-tesla-450-encode1 libnvidia-tesla-450-encode1:i386 libnvidia-tesla-450-glcore libnvidia-tesla-450-glcore:i386 libnvidia-tesla-450-glvkspirv libnvidia-tesla-450-glvkspirv:i386 libnvidia-tesla-450-ml1 libnvidia-tesla-450-nvcuvid1 libnvidia-tesla-450-nvcuvid1:i386 libnvidia-tesla-450-ptxjitcompiler1 libnvidia-tesla-450-ptxjitcompiler1:i386 libnvidia-tesla-450-rtcore libokular5core9 libopenexr25 libopengl0:i386 liborcus-0.16-0 liborcus-parser-0.16-0 libpango-1.0-0:i386 libpangocairo-1.0-0:i386 libpangoft2-1.0-0:i386 libpci3:i386 libpdfbox-java libperl5.32 libperl5.32:i386 libphonenumber8 libphonon4qt5-data libpipewire-0.3-0 libpipewire-0.3-modules libplymouth5 libpoppler-cpp0v5 libpoppler-glib8:i386 libpoppler102 libpoppler102:i386 libprimus-vk1 libprimus-vk1:i386 libprocesscore9 libprocessui9 libprocps8 libprotobuf23 libproxy1v5:i386 libpsl5:i386 libpython3.9 libpython3.9-minimal libpython3.9-stdlib libqhull-r8.0 libqpdf28 libqrcodegencpp1 libqt5networkauth5 libqt5qmlmodels5 libqt5qmlworkerscript5 libqt5quickparticles5 libqt5virtualkeyboard5 libraw1394-11:i386 libraw20 libre2-9 libreoffice-kf5 libreoffice-plasma libreoffice-qt5 libreoffice-sdbc-mysql libridl-java librtmp1:i386 libruby2.7 libsane1 libsane1:i386 libshout3:i386 libsidplay1v5 libslang2:i386 libsnmp40 libsnmp40:i386 libsoup2.4-1:i386 libsource-highlight-common libsource-highlight4v5 libspa-0.2-modules libsqlite3-0:i386 libssh2-1:i386 libstb0 libstb0:i386 libstdc++-10-dev libtag1v5:i386 libtag1v5-vanilla:i386 libtaskmanager6abi1 libthai0:i386 libtirpc-common libtirpc-dev libtirpc3 libtirpc3:i386 libtss2-esys-3.0.2-0 libtss2-mu0 libtss2-sys1 libtss2-tcti-cmd0 libtss2-tcti-device0 libtss2-tcti-mssim0 libtss2-tcti-swtpm0 libtwolame0:i386 libudfread0 libuno-cppu3 libuno-cppuhelpergcc3-3 libuno-purpenvhelpergcc3-3 libuno-sal3 libuno-salhelpergcc3-3 libunoil-java libunoloader-java libunwind8:i386 libusbmuxd6 libvmaf1 libvorbisidec1:i386 libwavpack1:i386 libwayland-server0:i386 libx264-164 libx265-192 libxcb-res0 libxcb-util1 libxcb-xinput0 libxstring-perl libxv1:i386 libz3-4 libz3-4:i386 libzxingcore1 linux-compiler-gcc-10-x86 linux-headers-5.10.0-9-amd64 linux-headers-5.10.0-9-common linux-image-5.10.0-9-amd64 linux-kbuild-5.10 mailcap mariadb-client-core-10.5 mariadb-server-core-10.5 media-types nvidia-egl-common nvidia-settings-tesla-450 nvidia-smi nvidia-tesla-450-alternative nvidia-tesla-450-driver nvidia-tesla-450-driver-bin nvidia-tesla-450-driver-libs nvidia-tesla-450-driver-libs:i386 nvidia-tesla-450-egl-icd nvidia-tesla-450-egl-icd:i386 nvidia-tesla-450-kernel-dkms nvidia-tesla-450-kernel-support nvidia-tesla-450-smi nvidia-tesla-450-vdpau-driver nvidia-tesla-450-vulkan-icd nvidia-tesla-450-vulkan-icd:i386 nvidia-vulkan-common par2 partitionmanager pci.ids perl-modules-5.32 perl-tk pipewire pipewire-bin plasma-disks plasma-workspace-data primus-libs:i386 printer-driver-indexbraille printer-driver-oki psmisc pulseaudio-module-gsettings python3-distro python3-fuse python3-ldb python3-mutagen python3-parted python3-pycryptodome python3-pylibacl python3-pyqt5.sip python3-pyxattr python3-talloc python3-tornado python3-websockets python3.9 python3.9-minimal qml-module-gsettings1.0 qml-module-org-kde-kitemmodels qml-module-org-kde-ksysguard qml-module-org-kde-people qml-module-org-kde-prison qml-module-org-kde-quickcharts qml-module-org-kde-userfeedback qml-module-qt-labs-platform qml-module-qtqml qml-module-qtquick-particles2 qml-module-qtwebengine qtgstreamer-plugins-qt5 qtspeech5-speechd-plugin rtmpdump ruby-rubygems ruby2.7 smartmontools systemd-timesyncd texlive-luatex tpm-udev uno-libs-private xkbset xserver-xorg-video-nvidia-tesla-450 xsettingsd yt-dlp The following packages have been kept back: gstreamer1.0-libav libasound2-plugins libasound2-plugins:i386 libavcodec58 libavcodec58:i386 libavformat58 libavresample4 libavresample4:i386 libavutil56 libavutil56:i386 libchromaprint1 libk3b7-extracodecs libmfx1 libpostproc55 libswresample3 libswresample3:i386 libswscale5 vlc-data vlc-plugin-base vlc-plugin-video-output The following packages will be upgraded: **(removed this list due to character limit)** 1046 upgraded, 376 newly installed, 126 to remove and 20 not upgraded. Need to get 1 676 MB archives. After this operation, 1 383 MB of additional disk space will be used. Do you want to continue? [Y/n] |
Using a Windows BIOS update on a Linux machine Posted: 31 Oct 2021 10:37 AM PDT I have an ASUS TUF A15 with a FA506IU BIOS, running Ubuntu 20.04. It's on version 304, and I've encountered some strange hardware issues. Someone suggested I update the BIOS, and, as per the official ASUS site, they are up to version 313. Now, that site prompts me for my BIOS name (which I happily provide) and my OS, which I list as "Others." That provides me with the option to download "FA506IV/IU/II/IH UL Certification." I have no idea what that is--I just want to update my BIOS. I check the Windows OS, and not only are there other downloads available, there is a "BIOS Update (Windows)" and a regular "BIOS" download at version 313. I'm put off by the fact that these updates only appear when I select Windows as the OS. Am I able to download and install that update that is based on the Windows OS, or is there maybe some sort of different file system for Windows that will screw up the BIOS if I do that? How can I safely update the BIOS on my machine? |
Running Puppet upon system reboot and shutdown Posted: 31 Oct 2021 06:45 AM PDT we are looking for a way to trigger a Puppet run when the system shuts down or reboots. While it's relatively simple to have SystemD execute a script in one-shot mode this would not guarantee Puppet to have enough time to finish its work. Did anybody implement something similar or has some advise how to set this up? Thanks |
How to automatically change DNS nameserver Posted: 31 Oct 2021 07:48 AM PDT My ISP's DNS server has problems resolving lots of important websites like google, github, gmail etc. As a hack I manually edited the /etc/resolv.conf file to Google's 8.8.8.8. But the changed file remodifies to my ISP's DNS service when there's a network change. How do I automatically set /etc/resolv.conf to Google's DNS in the event of a network change and when I restart my computer using bash scripting. I'm new to scripting on Linux. I'd need pointers on how to go about writing a script for this. Thanks. |
Failed to start OpenSSH server daemon Posted: 31 Oct 2021 10:06 AM PDT I am using centos7. I was trying to change the port of ssh and I changed the the port in /usr/lib/firewalld/services/ssh.xml I also change the port in the /etc/ssh/sshd_config file But when I tried to start the sshd service by "systemctl start sshd" then I am getting the following error. sshd.service - OpenSSH server daemon Loaded: loaded (/usr/lib/systemd/system/sshd.service; enabled; vendor preset: enabled) Active: activating (auto-restart) (Result: exit-code) since Wed 2019-03-27 16:36:20 IST; 26s ago Docs: man:sshd(8) man:sshd_config(5) Process: 20420 ExecStart=/usr/sbin/sshd -D $OPTIONS (code=exited, status=255) Main PID: 20420 (code=exited, status=255) Mar 27 16:36:20 localhost.localdomain systemd[1]: sshd.service: main process exited, code=exited, status=255/n/a Mar 27 16:36:20 localhost.localdomain systemd[1]: Failed to start OpenSSH server daemon. Mar 27 16:36:20 localhost.localdomain systemd[1]: Unit sshd.service entered failed state. Mar 27 16:36:20 localhost.localdomain systemd[1]: sshd.service failed. |
Why is my udev rule not working? Posted: 31 Oct 2021 09:04 AM PDT I need to automatically run my script /var/www/html/configWWW when any USB is plugged in to my Raspberry. UDEV RULE - /etc/udev/rules.d/myRule.rules ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="****", ATTR{idProduct}=="****", RUN+="/var/www/html/configWWW" MY SCRIPT - /var/www/html/configWWW #!/bin/bash file="/media/pi/USB/SymSif.xml" if [ -f "$file" ] then ( echo "it works: $(date)" >> /home/pi/Desktop/test.txt ) else ( echo "it does not works: $(date)" >> /home/pi/Desktop/test.txt ) fi On the other hand, if i run script from bash /var/www/html/configWWW , it works! Why doesn't my udev rule work like my bash command? |
Open Gnome Terminal window and execute 2 commands Posted: 31 Oct 2021 09:35 AM PDT I have a script which runs in the background (without terminal windows or TTY) and occasionally does something. I now want it to do another thing when it does something and it is to open a Gnome Terminal window and execute 2 commands. Actually, I only need to execute 1 command but I want to make the terminal window stay open so I can see the output of the command. The command prints both on stdout and stderr and its output changes over time, so just writing it to a file and sending some kind of notification wouldn't do the job very well. I can get Gnome Terminal to open a window and execute 1 command: gnome-terminal -e "sleep 10" I chose sleep as the long-running command for simplicity. However, when adding another command, no terminal window opens: gnome-terminal -e "echo test; sleep 10" What's the solution to this? |
iwlwifi: Failed to start INIT ucode: -110 Posted: 31 Oct 2021 08:57 AM PDT My desktop has lost wireless connectivity and I strongly suspect a hardware issue, but I would like to know how I can confirm that that is the problem before I buy a replacement. My reasons for thinking this are: I've exhausted my limited knowledge and Google searching from my phone isn't leading me anywhere. I'm really not familiar with this stuff, so any background info to help me understand what's going on here is very much appreciated! OS: Xubuntu 16.04 (relatively recently upgraded from 14.04) Kernel: 4.4.0-47 Edit: I found the solution to my lost connectivity, but I still don't know why. I am therefore leaving this question here in the hope that someone can answer my original question: how can I debug this kind of problem? |
Automatically switch display on lenovo docking and linux Posted: 31 Oct 2021 07:00 AM PDT I have a lenovo thinkpad with nvidia optimus and a mini docking station series 3. I want that while docked, it should automatically switch to an external monitor if possible and if I undock it, it should switch to the thinkpad lcd automatically. This should also work on the boot stage because there I have to type in a password for the encrypted disk (dm-crypt). I tried the following but it doesn't work: I created a file /etc/acpi/thinkpad-undock.sh (+ chmod a+x thinkpad-undock.sh ) which contains the following lines: #!/bin/sh xrandr --output LVDS-1 --auto --output DP-5.8 --off And also /etc/acpi/thinkpad-dock.sh #!/bin/sh prime-select nvidia # ensures that nvidia card is selected xrandr --output LVDS-1 --off --output DP-5.8 --auto And again chmod a+x thinkpad-dock.sh . Executing both scripts manually works. Than I created two files for handling the events: thinkpad-dock-lenovo event=ibm/hotkey LEN0068:00 00000080 00004010 action=/etc/acpi/thinkpad-dock.sh and also thinkpad-undock-lenovo event=ibm/hotkey LEN0068:00 00000080 00004011 action=/etc/acpi/thinkpad-undock.sh Then I reloaded the acpi daemon with /etc/init.d/acpid reload . However if I dock or undock the laptop it does nothing. I got the event number above by executing acpi_listen and then docking and undocking the laptop. So are there any ideas of how to make it work. Maybe the problem is solved by some desktop environment for example kde, but I am using xmonad and nevertheless, as indicated above, it should work even on boot stage independently of the desktop environment. I am running ubuntu 16.04 with kernel version 4.4.0-22. I tried also to add an udev rule as follow but it didn't work: ENV{EVENT}=="undock", KERNEL=="dock.0", SUBSYSTEM=="platform", RUN+="disper -s" ENV{EVENT}=="dock", KERNEL=="dock.0", SUBSYSTEM=="platform", RUN+="disper -s" I just noticed that the file dock has always the value 0, regardless if the laptop is docked or undocked. |
Sendmail Attachment Posted: 31 Oct 2021 08:15 AM PDT I was wondering if it's possible to include an attachment with sendmail. I am generating the following emailfile.eml files with the following layout From: Company Name <example@nowhere.com> To: recipient@madeup.com CC: someoneelse@place.com Subject: Generated Output Mime-Version: 1.0 This will be the body copy even though it's terrible I am sending these emails using # /usr/sbin/sendmail -t < emailfile.eml This part is working file but I would like to include an attachment to this email and I have not figured out how to do it |
What provides /etc/exports and how do I find that out? Posted: 31 Oct 2021 07:46 AM PDT I have two Debian virtual machines that were built from the same netinstall iso, but probably have different packages installed. One of them has an /etc/exports file for nfs mounts but the other one doesn't. I would like them both to have this file as installed by the package manager. I come from the Fedora world and were I still in it, I would yum whatprovides /etc/exports . I am told that in Debian land, I should do apt-file search . However, I am not getting any results with: apt-file update apt-file search /etc/exports What am I missing here? |
VPS: How to forward traffic to devices from public IP Posted: 31 Oct 2021 08:06 AM PDT My goal is to set up a public IP for a Android Smartphone which is running an "IP Cam" software. The interface can be accessed in local network on (example) 192.168.0.2:8080, but it has no public IP, as it should also work in the 3G network. I know there are services which offer a VPN with static dedicated addresses; the free one I found offers only PPTP with IPv6 (didn't work). The rest of them offer IPv4 for much higher cost than an actual VPS at Host1Plus with the lowest specs, so I went with this. At least I can practice and/or use the VPS for other projects. I followed this tutorial. Now I am at the point where I created a new user, assigned a static VPN Address in the OpenVPN Admin Panel to the account, and logged in with my device. Everything works so far. My android device gets the public IP of the VPS while browsing. I can ping the device's private VPN IP in the ssh terminal of the VPS. What is the next step? I tried this, but it doesn't really work. I am lost at this point. I never did anything with routes or forwarding. If I enter the public VPS IP right now, I get the openVPN Login Form as before. If I enter [PublicVPSIP]:8080 I get a "Server not reachable etc." error. At the end it should work like this. Android (running some service at port 8080) (VPN IP: 1.2.3.4) ▼ connects via openVPN to my VPS ▼ VPS (running openVPN Server) (Public IP: 123.123.123.123) ▼ Traffic from visitor at 123.123.123.123:8080 should be redirected/forwarded to my android device. (1.2.3.4:8080) |
Only find first few matched files using find? Posted: 31 Oct 2021 10:08 AM PDT Say there may be hundreds of *.txt files in a directory. I only want to find the first three *.txt files and then exit the searching process. How to achieve this using the find utility? I had a quick through on its man page, seemed not such a option for this. |
No comments:
Post a Comment