You are not logged in.

#1 2019-07-06 20:51:13

Vladdy
Member
Registered: 2017-01-30
Posts: 6

NordVPN package upgrade issue

I've been facing an issue with NordVPN binary installation after I compiled a package and install it at the end it says processing changes... and then

cannot remove /var/lib/nordvpn/data/insights.dat operation is not permitted

and also the same with the servers file

cannot remove /var/lib/nordvpn/data/servers.dat operation is not permitted

so when I run the following commands:

sudo chattr -i -a '/var/lib/nordvpn/data/insights.dat'
sudo chattr -i -a '/var/lib/nordvpn/data/servers.dat'
sudo chmod ugo+w '/var/lib/nordvpn/data/insights.dat'
sudo chmod ugo+w '/var/lib/nordvpn/data/servers.dat'

The installation works with no issues but after it is finished the permissions are locked/changed again and if I want to upgrade it the error comes back then I have to apply permissions again.

Here's the code I'm using:

# NordVPN script

pkgname=nordvpn-bin
pkgver=3.2.0_2
pkgrel=1
pkgdesc="NordVPN CLI tool for Linux"
arch=('x86_64')
url="https://nordvpn.com/download/linux/"
license=('custom')
depends=('net-tools' 'libxslt' 'iptables' 'procps' 'iproute2')
provides=('nordvpn')
conflicts=('openvpn-nordvpn')
install=nordvpn-bin.install
source_x86_64=("https://repo.nordvpn.com/deb/nordvpn/debian/pool/main/nordvpn_${pkgver//_/-}_amd64.deb")
sha256sums_x86_64=('c069d71f6b3fa40b27be1a7a1c842a114fdbf1dce8dbb94cb761e5fa3078599c')

package() {
    bsdtar -O -xf *.deb data.tar.xz | bsdtar -C "${pkgdir}" -xJf -

    mv "${pkgdir}/usr/sbin/nordvpnd" "${pkgdir}/usr/bin"
    rm -r "${pkgdir}/etc/init.d"
    rm -r "${pkgdir}/usr/sbin"
}

This is nordvpn.install file:

post_install() {
  echo ':: In order to enable nordvpn you have to start the following service:'
  echo '     sudo systemctl enable --now nordvpnd'
}

pre_remove() {
  chattr -i /var/lib/nordvpn/data/*
} 

The fact is it didn't happen with the previous versions of the package. And I din't do any changes to the system as I recall of.

Then, is it an issue in my system or rather with the package itself?

Offline

#2 2019-07-06 20:55:28

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: NordVPN package upgrade issue

Pacman (running as root) cannot remove a file?

EDIT: just use the OpenVPN from [extra], no need to use their client from the quick googling I just did. https://nordvpn.com/tutorials/linux/openvpn/

Last edited by graysky (2019-07-06 20:57:48)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#3 2019-07-06 20:57:37

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: NordVPN package upgrade issue

Moving to AUR Issues...


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#4 2019-07-06 21:01:09

Vladdy
Member
Registered: 2017-01-30
Posts: 6

Re: NordVPN package upgrade issue

graysky wrote:

Pacman (running as root) cannot remove a file?

EDIT: just use the OpenVPN from [extra], no need to use their client from the quick googling I just did. https://nordvpn.com/tutorials/linux/openvpn/

No, only if I run

chattr

and then apply the permissions then I can remove it.

The interface is not an issue it is fine and easy to use it with the terminal. The issue is with the package upgrade.

Last edited by Vladdy (2019-07-06 21:09:53)

Offline

#5 2019-07-06 21:10:32

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: NordVPN package upgrade issue

graysky wrote:

...just use the OpenVPN from [extra], no need to use their client from the quick googling I just did. https://nordvpn.com/tutorials/linux/openvpn/


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#6 2019-07-06 21:15:56

loqs
Member
Registered: 2014-03-06
Posts: 17,196

Re: NordVPN package upgrade issue

https://aur.archlinux.org/cgit/aur.git/ … 3f56b272d5
Would indicate it is not your system.

Offline

#7 2019-07-06 21:25:23

Vladdy
Member
Registered: 2017-01-30
Posts: 6

Re: NordVPN package upgrade issue

loqs wrote:

https://aur.archlinux.org/cgit/aur.git/ … 3f56b272d5
Would indicate it is not your system.

I see, they have added pre_remove hook but it seems to stop working now either. Thanks for pointing out.

Offline

#8 2019-07-07 12:19:13

loqs
Member
Registered: 2014-03-06
Posts: 17,196

Re: NordVPN package upgrade issue

The pre_remove hook is not used on package upgrade that would require a pre_upgrade hook.

Offline

Board footer

Powered by FluxBB