انجمنهای فارسی اوبونتو
تازه کار => انجمن تازهکاران => نویسنده: PL4Y در 26 مهر 1401، 03:13 بظ
-
برای نصب یک برنامه تو سرورم نیاز دارم این دستور قبلش انجام بشه ولی هر بار که این اجرا میکنم خطا میده ممنون میشم اگه راهنماییم کنید
Welcome to Ubuntu 20.04 LTS (GNU/Linux 5.4.0-28-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
The list of available updates is more than a week old.
To check for new updates run: sudo apt update
Last login: Tue Oct 18 11:38:14 2022 from 5.121.176.88
root@qqq1:~# apt-get update -y && apt-get upgrade -y
Hit:1 http://us.archive.ubuntu.com/ubuntu focal InRelease
Err:1 http://us.archive.ubuntu.com/ubuntu focal InRelease
Couldn't create temporary file /tmp/apt.conf.oIZ38R for passing config to apt-key
Ign:2 http://security.ubuntu.com/ubuntu focal-security InRelease
Ign:3 http://us.archive.ubuntu.com/ubuntu focal-updates InRelease
Err:4 http://security.ubuntu.com/ubuntu focal-security Release
Could not open file /var/lib/apt/lists/partial/security.ubuntu.com_ubuntu_dists_focal-security_Release - open (30: Read-only file system) [IP: 185.125.190.36 80]
Ign:5 http://us.archive.ubuntu.com/ubuntu focal-backports InRelease
Err:6 http://us.archive.ubuntu.com/ubuntu focal-updates Release
Could not open file /var/lib/apt/lists/partial/us.archive.ubuntu.com_ubuntu_dists_focal-updates_Release - open (30: Read-only file system) [IP: 91.189.91.38 80]
Err:7 http://us.archive.ubuntu.com/ubuntu focal-backports Release
Could not open file /var/lib/apt/lists/partial/us.archive.ubuntu.com_ubuntu_dists_focal-backports_Release - open (30: Read-only file system) [IP: 91.189.91.39 80]
Reading package lists... Done
W: chown to _apt:root of directory /var/lib/apt/lists/partial failed - SetupAPTPartialDirectory (30: Read-only file system)
W: chmod 0700 of directory /var/lib/apt/lists/partial failed - SetupAPTPartialDirectory (30: Read-only file system)
W: chown to _apt:root of directory /var/lib/apt/lists/auxfiles failed - SetupAPTPartialDirectory (30: Read-only file system)
W: chmod 0700 of directory /var/lib/apt/lists/auxfiles failed - SetupAPTPartialDirectory (30: Read-only file system)
W: Not using locking for read only lock file /var/lib/apt/lists/lock
W: Problem unlinking the file /var/lib/apt/lists/partial/.apt-acquire-privs-test.G8czca - IsAccessibleBySandboxUser (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/.apt-acquire-privs-test.9xElh8 - IsAccessibleBySandboxUser (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/.apt-acquire-privs-test.WkJGib - IsAccessibleBySandboxUser (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/.apt-acquire-privs-test.xbXITa - IsAccessibleBySandboxUser (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/us.archive.ubuntu.com_ubuntu_dists_focal_InRelease - PrepareFiles (30: Read-only file system)
W: chown to _apt:root of file /var/lib/apt/lists/us.archive.ubuntu.com_ubuntu_dists_focal_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chmod 0600 of file /var/lib/apt/lists/us.archive.ubuntu.com_ubuntu_dists_focal_InRelease failed - Item::QueueURI (30: Read-only file system)
W: chown to root:root of file /var/lib/apt/lists/us.archive.ubuntu.com_ubuntu_dists_focal_InRelease failed - 400::URIFailure (30: Read-only file system)
W: chmod 0644 of file /var/lib/apt/lists/us.archive.ubuntu.com_ubuntu_dists_focal_InRelease failed - 400::URIFailure (30: Read-only file system)
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://us.archive.ubuntu.com/ubuntu focal InRelease: Couldn't create temporary file /tmp/apt.conf.oIZ38R for passing config to apt-key
W: Problem unlinking the file /var/lib/apt/lists/partial/security.ubuntu.com_ubuntu_dists_focal-security_InRelease - PrepareFiles (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/us.archive.ubuntu.com_ubuntu_dists_focal-updates_InRelease - PrepareFiles (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/security.ubuntu.com_ubuntu_dists_focal-security_Release - PrepareFiles (30: Read-only file system)
E: The repository 'http://security.ubuntu.com/ubuntu focal-security Release' no longer has 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.
W: Problem unlinking the file /var/lib/apt/lists/partial/us.archive.ubuntu.com_ubuntu_dists_focal-backports_InRelease - PrepareFiles (30: Read-only file system)
W: Problem unlinking the file /var/lib/apt/lists/partial/us.archive.ubuntu.com_ubuntu_dists_focal-updates_Release - PrepareFiles (30: Read-only file system)
E: The repository 'http://us.archive.ubuntu.com/ubuntu focal-updates Release' no longer has 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.
W: Problem unlinking the file /var/lib/apt/lists/partial/us.archive.ubuntu.com_ubuntu_dists_focal-backports_Release - PrepareFiles (30: Read-only file system)
E: The repository 'http://us.archive.ubuntu.com/ubuntu focal-backports Release' no longer has 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.
W: Problem unlinking the file /var/cache/apt/pkgcache.bin - RemoveCaches (30: Read-only file system)
W: Problem unlinking the file /var/cache/apt/srcpkgcache.bin - RemoveCaches (30: Read-only file system)
root@qqq1:~#
-
فکر کنم سرورتون قابل نوشتن و خواندن نیست.
-
خروجی این دستورات رو بذارید.
mount
findmnt
فکر کنم سرورتون قابل نوشتن و خواندن نیست.
قابل خوندن که هست ولی احتمالا فایلسیستم روت به صورت فقط خواندنی سوار شده.
-
Welcome to Ubuntu 20.04 LTS (GNU/Linux 5.4.0-28-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
The list of available updates is more than a week old.
To check for new updates run: sudo apt update
Last login: Tue Oct 18 11:38:14 2022 from 5.121.176.88
root@qqq1:~# mount
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,noexec,relatime,size=474264k,nr_inodes=118 566,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmod e=000)
tmpfs on /run type tmpfs (rw,nosuid,nodev,noexec,relatime,size=100480k,mode=755)
/dev/vda1 on / type ext4 (ro,relatime,errors=remount-ro)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relat ime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup2 on /sys/fs/cgroup/unified type cgroup2 (rw,nosuid,nodev,noexec,relatime, nsdelegate)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xa ttr,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
none on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpu set)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,de vices)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blki o)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatim e,cpu,cpuacct)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,fr eezer)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,mem ory)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hu getlb)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,re latime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime ,perf_event)
cgroup on /sys/fs/cgroup/rdma type cgroup (rw,nosuid,nodev,noexec,relatime,rdma)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=28,pgrp=1,time out=0,minproto=5,maxproto=5,direct,pipe_ino=13337)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatim e)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /run/user/123 type tmpfs (rw,nosuid,nodev,relatime,size=100476k,mode=70 0,uid=123,gid=65534)
gvfsd-fuse on /run/user/123/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime, user_id=123,group_id=65534)
tmpfs on /run/user/0 type tmpfs (rw,nosuid,nodev,relatime,size=100476k,mode=700)
root@qqq1:~# findmnt
-
خروجی این دستورات رو بذارید.
mount
findmnt
فکر کنم سرورتون قابل نوشتن و خواندن نیست.
قابل خوندن که هست ولی احتمالا فایلسیستم روت به صورت فقط خواندنی سوار شده.
Welcome to Ubuntu 20.04 LTS (GNU/Linux 5.4.0-28-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
The list of available updates is more than a week old.
To check for new updates run: sudo apt update
Last login: Tue Oct 18 11:38:14 2022 from 5.121.176.88
root@qqq1:~# mount
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,noexec,relatime,size=474264k,nr_inodes=118 566,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmod e=000)
tmpfs on /run type tmpfs (rw,nosuid,nodev,noexec,relatime,size=100480k,mode=755)
/dev/vda1 on / type ext4 (ro,relatime,errors=remount-ro)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relat ime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup2 on /sys/fs/cgroup/unified type cgroup2 (rw,nosuid,nodev,noexec,relatime, nsdelegate)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xa ttr,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
none on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpu set)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,de vices)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blki o)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatim e,cpu,cpuacct)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,fr eezer)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,mem ory)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hu getlb)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,re latime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime ,perf_event)
cgroup on /sys/fs/cgroup/rdma type cgroup (rw,nosuid,nodev,noexec,relatime,rdma)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=28,pgrp=1,time out=0,minproto=5,maxproto=5,direct,pipe_ino=13337)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatim e)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /run/user/123 type tmpfs (rw,nosuid,nodev,relatime,size=100476k,mode=70 0,uid=123,gid=65534)
gvfsd-fuse on /run/user/123/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime, user_id=123,group_id=65534)
tmpfs on /run/user/0 type tmpfs (rw,nosuid,nodev,relatime,size=100476k,mode=700)
root@qqq1:~# findmnt
-
فایلسیستم روت به صورت فقط خواندنی سوار شده. به همین دلیل هر تغییری که بخواهید توی فایلهای روی دیسک مجازی بدید، به مشکل میخورید.
هوم و غیره هم جدا نیستند. در نتیجه نمیشه چیزهای داخل اونها رو هم تغییر داد.
خروجی این دوتا دستور رو هم بفرستید.
cat /etc/fstab
cat /proc/cmdline
-
فایلسیستم روت به صورت فقط خواندنی سوار شده. به همین دلیل هر تغییری که بخواهید توی فایلهای روی دیسک مجازی بدید، به مشکل میخورید.
هوم و غیره هم جدا نیستند. در نتیجه نمیشه چیزهای داخل اونها رو هم تغییر داد.
خروجی این دوتا دستور رو هم بفرستید.
cat /etc/fstab
cat /proc/cmdline
Welcome to Ubuntu 20.04 LTS (GNU/Linux 5.4.0-28-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
The list of available updates is more than a week old.
To check for new updates run: sudo apt update
Last login: Tue Oct 18 11:38:14 2022 from 5.121.176.88
root@qqq1:~# cat /etc/fstab
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sda1 during installation
/dev/vda1 / ext4 errors=remount-ro 0 1
/dev/vda2 none swap sw 0 0
root@qqq1:~# cat /proc/cmdline
BOOT_IMAGE=/boot/vmlinuz-5.4.0-28-generic root=UUID=9de45e18-29e7-4330-b5ab-8a272f87aa36 ro net.ifnames=0 biosdevname=0 netcfg/do_not_use_netplan=true
root@qqq1:~#
-
انگار مشکل اینجاست که ro به خط فرمان کرنل داده شده.
این باعث میشه که initramfs، فایلسیستم روت رو به صورت فقط خواندنی سوار کنه.
توی fstab هم تعریف نشده که فایلسیستم روت به صورت خواندنی نوشتنی سوار بشه یا به صورت فقط خواندنی. چیزی دربارش نگفته.
سعی کنید با دستور mount، فایلسیستم روت رو به صورت خواندنی نوشتنی سوار کنید و ببینید چی میشه.
mount -o remount,rw /
اگه درست شد، بدونید موقتیه و با یه راهاندازی مجدد، به حالت قبل بر میگرده.