LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-28-2022, 07:51 PM   #1
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 20.04
Posts: 2,116

Rep: Reputation: 73
phpMyAdmin can't access /var/lib/php/sessions


I got this error this morning while trying to open phpMyAdmin.

Up to now, everything was fine!

Quote:
Error during session start; please check your PHP and/or webserver log file and configure your PHP installation properly. Also ensure that cookies are enabled in your browser.

session_start(): open(SESSION_FILE, O_RDWR) failed: Read-only file system (30)

session_start(): Failed to read session data: files (path: /var/lib/php/sessions)
These are the permissions on the server. Checking on the internet, these permissions seem OK

Quote:
pedro@ebs-105422:/var/lib/php$ ls -al
total 196
drwxr-xr-x 4 root root 4096 Oct 7 2021 .
drwxr-xr-x 50 root root 4096 Mar 21 06:14 ..
drwxr-xr-x 3 root root 4096 Oct 7 2021 modules
drwx-wx-wt 2 root root 184320 Aug 28 19:09 sessions
Any tips please?

I get this with stat:

Quote:
pedro@ebs-105422:/var/lib/php/sessions$ sudo stat -c "%a" /var/lib/php/sessions
1733
Which is what it should be, I believe.

Tried changing to 1777 but doesn't work.

Quote:
pedro@ebs-105422:/var/lib/php/sessions$ sudo chmod 1777 /var/lib/php/sessions
chmod: changing permissions of '/var/lib/php/sessions': Read-only file system
pedro@ebs-105422:/var/lib/php/sessions$ sudo stat -c "%a" /var/lib/php/sessions
1733
Normally, I upload stuff with Filezilla. Now I can't create a directory on the server. Always worked before.

Quote:
Command: mkdir "21BE1cw"
Error: mkdir /var/www/fastmarker.wang/public_html/21BE1cw: received failure with description 'Failure'
Command: mkdir "/var/www/fastmarker.wang/public_html/21BE1cw"
Error: mkdir /var/www/fastmarker.wang/public_html/21BE1cw: received failure with description 'Failure'

Last edited by Pedroski; 08-28-2022 at 08:23 PM.
 
Old 08-28-2022, 08:55 PM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,760

Rep: Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931Reputation: 5931
Quote:
chmod: changing permissions of '/var/lib/php/sessions': Read-only file system
Whatever filesystem /var/lib/php/sessions resides on has become read only for whatever reason. Many distributions use the option errors=remount-ro for the root filesystem in /etc/fstab. Make sure it isn't full either.
 
Old 08-29-2022, 02:04 AM   #3
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 20.04
Posts: 2,116

Original Poster
Rep: Reputation: 73
Thanks for your reply!

I didn't access the server on Sunday, but this problem began for me on Monday morning.

A bit later on Monday morning, my webpage and phpMyAdmin were not accessible at all.

I complained to the host after repeated failures. They must have updated their system either Saturday night or Sunday, because everything was fine on Saturday during the day.

They reacted quite fast, and a little while later, everything was OK again. Don't know what the problem was.

They must have updated something.

Works now!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Problem with /var. Something is filling up /var, esp. /lib/snapd/snaps. rpalmer7 Linux - Newbie 5 02-15-2019 10:01 AM
/var/cache/yum and /var/lib/rpm getting BIG. How to safely pare down? SharpyWarpy Linux - General 3 02-29-2012 01:17 AM
file /var/lib/named/var/named/reverse/named.zero failed: file not found Toadman Linux - Software 15 03-18-2009 07:01 PM
Compromised? Files "/usr/lib.hwm", "/usr/lib.pwd", "/usr/lib.pwi" Klaus Pforte Linux - Security 4 09-28-2004 11:33 PM
Moving /var/adm and /var/lib - why does it hurt? J_Szucs Linux - General 1 09-15-2004 06:46 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 07:38 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration