Cannot read files after moving to new server

Re: 2.3.1

by Lê Hoa`n -
Number of replies: 7

Hi Ken, 

now, i have some problems, when moved to other server, i can not upload any file on system. I had a error : 

"can not read file, either file does not exist or there are permission problems"

And then, i changed from suggestions of you

chown apache:apache * -R

chmod ugo+rw * -R.

But i have an another error: 

"can not create local file pool directories, please verify permissions in dataroot"

Althought i set permission for moodledata directory: 777.

Can you help this problem? 

Thanks.

you can see from image which i captured.

Attachment Error can not create local fileJPG
In reply to Lê Hoa`n

Re: 2.3.1

by Ken Task -
Picture of Particularly helpful Moodlers

The item highlighted behind the error message looks to be a mount point of a remote server?  What is B...NMTH?

The items in your file picker/uploader don't look complete.  Where is 'upload a file'?

'spirit of sharing', Ken

 

Attachment uploadfile.png
In reply to Ken Task

Re: 2.3.1

by Lê Hoa`n -

Thanks for reply, 

i renamed "Upload a file" to" BaigiangNMTH", but i can't upload any file on system. 

 

Attachment Upload.jpg
In reply to Lê Hoa`n

Re: 2.3.1

by Ken Task -
Picture of Particularly helpful Moodlers

@ Lê Hoa`n

"moved" to a different server.  Server is what OS?

uname -an

If CentOS 6.x/RedHat Enterprise 6, is SELINUX running?

/usr/sbin/sestatus

if output of above shows:

Current mode:                   enforcing

it is on and might be the reason.  Change from 'enforcing' to 'permissive':

nano /etc/selinux/config

# SELINUX= can take one of these three values:
#    enforcing - SELinux security policy is enforced.
#    permissive - SELinux prints warnings instead of enforcing.
#    disabled - SELinux is fully disabled.
SELINUX=permissive

Reset of SELINUX requires restart of system.

Were *all* the files/folders in moodledata moved to the new server?

From /var/www/ of old server:

scp moodledata root@newserver:/var/www/

When using scp as above moodledata gets tagged as belonging to root:root.

moodledata is located in /var/www/ apache already has access to that location.

Logged on as root user new server:

cd /var/www/

chown apache:apache moodledata -R

chmod ugo+rwx moodledata -R

Check your apache access/error logs.

If all those checkout, turn on debugging.

'spirit of sharing', Ken

In reply to Ken Task

Re: 2.3.1

by Lê Hoa`n -

Hi Ken, 

Thank you so much, i check again my server and use your suggestions. My server works very well. 

Thanks. 

In reply to Ken Task

Re: 2.3.1

by umesh chavan -


Hello Ken,

Hope I will get solution from you!!smile

I have latest Moodle installation on my local server and accessible over LAN.

The conversation with Davo Smith, i have copied here.

i tried installing latest ghost script but the problem still persists.

secondly as you advised for using Annotate PDF,

1. If I disable the Feedback PDF, to use annotate PDF, it does not show Annotation Tab.

2. when i tried opening Annotate PDF, there was an error so I could not apply it (???)

3. Can we rotate the PDF while checking ( as if there is original file in landscape page format, it shows in annotation as portrait only)

How do I resolve the error?


the help link does not relate to the problem.

Thanks

Umesh

In reply to umesh chavan

Re: 2.3.1

by Ken Task -
Picture of Particularly helpful Moodlers

Emma and Davo have both recommended un-installing the old plugin and
use the built in.  I'd add +1 to those suggestions.  Adding to an existing
posting about an issue that's not really related isn't really going to get you a different answer.

About the only thing I would tell you is to check on the file which is
what the error reports - but you've said that help link isn't the problem?

Path to noodle's data directory can be found in config.php file of the code.
The '....' below you fill i with all those numbers/letters seen in the Debug info.

cd /path/to/moodledata/filedir/

is there a 8c directory?
cd 8c
is there a 96 directory?
cd 96
is there a file? 8c96.... 865?
What are owneership/permissions on that file?
What are ownerships/permissions on 8c on 96 as well?

Is it a PDF?

copy the 8c96....865 file to another location AND change it's name  to check.pdf

cp 8c96....865 c:\check.pdf

See if you can open the check.pdf file.

'spirit of sharing', Ken

In reply to Ken Task

Re: 2.3.1

by umesh chavan -

Hello Ken,

Thanks for giving guideline, I checked for the folders such as "8c" "96" etc in the respective error messages, as I created folders in the moodledata and the respective location, with continue button the debugging mode gave me more no of such folder errors, so created all the folders and the files.

The file I created was like right click and create new note.txt files and renamed it with the encrypted file name and amazingly it worked for me.


Thanks once again.

Umesh