Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a WAMP server running on Windows 7 and I want to move the mysql data files to a network share (A NAS device).

I stopped the WAMP server, created a drive letter mapping to a share on the NAS, copied the files from the old location to a folder under the new share

and in my.ini changed
datadir=c:/wamp/bin/mysql/mysql5.1.36/data
to:
datadir=s:/wamp_files (s: is mapped to the \NAS\SHARE and an wamp_files is a folder)

and restarted the WAMP server.

It now says (in mysql.log):

wampmysqld: File '.\mysql-bin.index' not found (Errcode: 13) 111116 12:27:24 [ERROR] Aborting

111116 12:27:24 [Note] wampmysqld: Shutdown complete

and the mysql service refuses to start.

Any ideas anyone?

(The NAS is a netgear readyNAS device and the share is set for public access)

share|improve this question

closed as off-topic by Michael Hampton Oct 10 at 13:44

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions must be relevant to professional system administration. Server Fault is dedicated to professional system and network administrators. End user and enthusiast questions are off-topic (contact your system administrator or hire a professional to help you out). Please see the Help Center for more information." – Michael Hampton
If this question can be reworded to fit the rules in the help center, please edit the question.

1 Answer 1

up vote 2 down vote accepted

Drive mappings that you create under your login, i.e. through Explorer, aren't available to a service. There's a stackoverflow question that suggests some work arounds and one potential solution (the answer by ForcePush).

The more robust option would be to see if you can change the datadir to point to a network share, rather than a mapped network drive.

share|improve this answer
    
right on the money :) I actually started with it pointing to a network share but probably had some slashes wrong and it did not work. switched now back to network share and its just fine. Thanks. –  epeleg Nov 16 '11 at 13:19
    
@epeleg, glad I could help =) –  Rob Nov 16 '11 at 13:33
    
amazingly I find myself stuck with exactly the same issue a year an a half later... what should be the exact syntax for the datadir= to point to a UNC and which user is the service using to authenticate against this share ? (maybe its a permissions issue?) –  epeleg May 9 '13 at 7:03

Not the answer you're looking for? Browse other questions tagged or ask your own question.