Migrazione da Locale a Server e non accede più!
Ho spostato un sito fatto in locale su MAMP sul server, vedo la home senza problemi ma appena provo ad accedere al sito mi dice che la pagina node/1?destination=node%2F1 non è stata trovata (404).
Nel db ho modificato tutti path aggiornandoli a quelli del server, ora sul server (aruba) è in una sottocartella e leggendo qua e là penso potrebbe essere dovuto al file .htaccess.... ma non so davvero come sistemarlo!

Risposte
Per vedere se dipende dal
Per vedere se dipende dal file .htaccess puoi provare ad eliminarlo temporaneamente dal server e provare a riaccedere.
Grazie, non pensavo si
Grazie, non pensavo si potesse fare così... purtroppo però non è cambiato nulla!
Di siti joomla ne ho spostati parecchi, per drupal è la prima volta, ma non capisco cosa manchi...
L'htaccess era stato
L'htaccess era stato modificato o è originale (default installazione)? Puoi accedere tramite http://tuosito.it/?q=node/1 o anche così ti dà un 404?
Anche così 404... l'htaccess
Anche così 404...
l'htaccess non l'ho mai modificato ma credo possa essere importante che sul server c'è un wordpress e per ora, essendo solo una demo, questo drupal è in una sottocartella, quindi miosito.it/drupal
dove in miosito.it c'è wordpress.
Ti mando in privato gli url :)
Grazie e buon anno!
Prova questa soluzione: edita
Prova questa soluzione: edita l'.htaccess e cerca questa linea
# RewriteBase /drupalmodificala in
RewriteBase /masteroncologysalva e vedi se risolve. Altrimenti proviamo a disattivare i clean-url.
Ti copio l'htaccess perchè
Ti copio l'htaccess perchè dato che nella root c'è un wordpress non vorrei che fosse quello il problema:
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
Deve esserci un .htaccess
Deve esserci un .htaccess dentro la sotto-cartella di drupal. Prova a modificare questo, non quello sulla root e posta cosa succede.
ecco.... non c'è! :|
ecco.... non c'è! :|
Puoi copiarlo dal pacchetto
Puoi copiarlo dal pacchetto di drupal ed effettuare la modifica sopra.
Semplicemente non avevo
Semplicemente non avevo caricato quel file...
Ora l'ho caricato e mi dava Internal Server Error, allora l'ho modificato come mi avevi detto tu e sempre ISE, quindi l'ho riuploadato tutto e sempre uguale... permessi tutto 755, sono su Aruba...
Grazie di tutto il tempo che mi dedichi!
Prova questa
Prova questa versione:
<FilesMatch "\.(engine|inc|info|install|module|profile|test|po|sh|.*sql|theme|tpl(\.php)?|xtmpl|svn-base)$|^(code-style\.pl|Entries.*|Repository|Root|Tag|Template|all-wcprops|entries|format)$">
Order allow,deny
</FilesMatch>
ErrorDocument 404 /index.php
<Files favicon.ico>
ErrorDocument 404 "The requested file favicon.ico was not found.
</Files>
<IfModule mod_php4.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0
</IfModule>
<IfModule sapi_apache2.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0
</IfModule>
<IfModule mod_php5.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /masteroncology
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
</IfModule>
Allora, ecco gli
Allora, ecco gli aggiornamenti...
Stanotte ho cercato in lungo e in largo sui vari forum, trovando che l'htaccess di drupal potrebbe creare problemi con aruba, consigliavano quindi di commentare la seconda e terza riga dell'htaccess presente in sites/default/files e di commentare queste linee nell'htaccess della directory proncipale di drupal:
#Options -Indexes
#Options +FollowSymLinks
#DirectoryIndex index.php
prima di fare tutto questo dal log degli errori saltava effettivamente fuori un errore dovuto all'htaccess, con queste modifiche ora non più.
Tuttavia non è cambiato nulla.
Ora ho provato ad inserire l'htaccess che mi hai fornito tu, anche stavolta senza risultati... Ho inoltrato una richiesta ad aruba, spero ci capiscano qualcosa...
Per la cronaca, l'htaccess
Per la cronaca, l'htaccess modificato prima di provare con il tuo, era questo:
#
# Apache/PHP/Drupal settings:
#
# Protect files and directories from prying eyes.
<FilesMatch "\.(engine|inc|info|install|make|module|profile|test|po|sh|.*sql|theme|tpl(\.php)?|xtmpl|svn-base)$|^(code-style\.pl|Entries.*|Repository|Root|Tag|Template|all-wcprops|entries|format)$">
Order allow,deny
</FilesMatch>
# Don't show directory listings for URLs which map to a directory.
Options -Indexes
# Follow symbolic links in this directory.
Options +FollowSymLinks
# Make Drupal handle any 404 errors.
ErrorDocument 404 /index.php
# Force simple error message for requests for non-existent favicon.ico.
<Files favicon.ico>
# There is no end quote below, for compatibility with Apache 1.3.
ErrorDocument 404 "The requested file favicon.ico was not found.
</Files>
# Set the default handler.
DirectoryIndex index.php
# Override PHP settings. More in sites/default/settings.php
# but the following cannot be changed at runtime.
# PHP 4, Apache 1.
<IfModule mod_php4.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0
</IfModule>
# PHP 4, Apache 2.
<IfModule sapi_apache2.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0
</IfModule>
# PHP 5, Apache 1 and 2.
<IfModule mod_php5.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0
</IfModule>
# Requires mod_expires to be enabled.
<IfModule mod_expires.c>
# Enable expirations.
ExpiresActive On
# Cache all files for 2 weeks after access (A).
ExpiresDefault A1209600
<FilesMatch \.php$>
# Do not allow PHP scripts to be cached unless they explicitly send cache
# headers themselves. Otherwise all scripts would have to overwrite the
# headers set by mod_expires if they want another caching behavior. This may
# fail if an error occurs early in the bootstrap process, and it may cause
# problems if a non-Drupal PHP file is installed in a subdirectory.
ExpiresActive Off
</FilesMatch>
</IfModule>
# Various rewrite rules.
<IfModule mod_rewrite.c>
RewriteEngine on
# If your site can be accessed both with and without the 'www.' prefix, you
# can use one of the following settings to redirect users to your preferred
# URL, either WITH or WITHOUT the 'www.' prefix. Choose ONLY one option:
#
# To redirect all users to access the site WITH the 'www.' prefix,
# (http://example.com/... will be redirected to http://www.example.com/...)
# adapt and uncomment the following:
# RewriteCond %{HTTP_HOST} ^example\.com$ [NC]
# RewriteRule ^(.*)$ http://www.example.com/$1 [L,R=301]
#
# To redirect all users to access the site WITHOUT the 'www.' prefix,
# (http://www.example.com/... will be redirected to http://example.com/...)
# uncomment and adapt the following:
# RewriteCond %{HTTP_HOST} ^www\.example\.com$ [NC]
# RewriteRule ^(.*)$ http://example.com/$1 [L,R=301]
# Modify the RewriteBase if you are using Drupal in a subdirectory or in a
# VirtualDocumentRoot and the rewrite rules are not working properly.
# For example if your site is at http://example.com/drupal uncomment and
# modify the following line:
# RewriteBase /drupal
#
# If your site is running in a VirtualDocumentRoot at
" title="http://example.com/,
">http://example.com/,
# uncomment the following line:
RewriteBase /masteroncology
# Rewrite URLs of the form 'x' to the form 'index.php?q=x'.
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
</IfModule>
# $Id: .htaccess,v 1.90.2.5 2010/02/02 07:25:22 dries Exp $
Il log errori di aruba mi dava questo errore:
/web/htdocs/www.contrienrico.it/home/masteroncology/.htaccess: Option Indexes not allowed heree quindi commentando in questo modo non capita più, ma l'errore interno del server rimane:
#
# Apache/PHP/Drupal settings:
#
# Protect files and directories from prying eyes.
<FilesMatch "\.(engine|inc|info|install|make|module|profile|test|po|sh|.*sql|theme|tpl(\.php)?|xtmpl|svn-base)$|^(code-style\.pl|Entries.*|Repository|Root|Tag|Template|all-wcprops|entries|format)$">
Order allow,deny
</FilesMatch>
# Don't show directory listings for URLs which map to a directory.
#Options -Indexes
# Follow symbolic links in this directory.
#Options +FollowSymLinks
# Make Drupal handle any 404 errors.
ErrorDocument 404 /index.php
# Force simple error message for requests for non-existent favicon.ico.
<Files favicon.ico>
# There is no end quote below, for compatibility with Apache 1.3.
ErrorDocument 404 "The requested file favicon.ico was not found.
</Files>
# Set the default handler.
#DirectoryIndex index.php
# Override PHP settings. More in sites/default/settings.php
# but the following cannot be changed at runtime.
# PHP 4, Apache 1.
<IfModule mod_php4.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0
</IfModule>
# PHP 4, Apache 2.
<IfModule sapi_apache2.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0
</IfModule>
# PHP 5, Apache 1 and 2.
<IfModule mod_php5.c>
php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0
</IfModule>
# Requires mod_expires to be enabled.
<IfModule mod_expires.c>
# Enable expirations.
ExpiresActive On
# Cache all files for 2 weeks after access (A).
ExpiresDefault A1209600
<FilesMatch \.php$>
# Do not allow PHP scripts to be cached unless they explicitly send cache
# headers themselves. Otherwise all scripts would have to overwrite the
# headers set by mod_expires if they want another caching behavior. This may
# fail if an error occurs early in the bootstrap process, and it may cause
# problems if a non-Drupal PHP file is installed in a subdirectory.
ExpiresActive Off
</FilesMatch>
</IfModule>
# Various rewrite rules.
<IfModule mod_rewrite.c>
RewriteEngine on
# If your site can be accessed both with and without the 'www.' prefix, you
# can use one of the following settings to redirect users to your preferred
# URL, either WITH or WITHOUT the 'www.' prefix. Choose ONLY one option:
#
# To redirect all users to access the site WITH the 'www.' prefix,
# (http://example.com/... will be redirected to http://www.example.com/...)
# adapt and uncomment the following:
# RewriteCond %{HTTP_HOST} ^example\.com$ [NC]
# RewriteRule ^(.*)$ http://www.example.com/$1 [L,R=301]
#
# To redirect all users to access the site WITHOUT the 'www.' prefix,
# (http://www.example.com/... will be redirected to http://example.com/...)
# uncomment and adapt the following:
# RewriteCond %{HTTP_HOST} ^www\.example\.com$ [NC]
# RewriteRule ^(.*)$ http://example.com/$1 [L,R=301]
# Modify the RewriteBase if you are using Drupal in a subdirectory or in a
# VirtualDocumentRoot and the rewrite rules are not working properly.
# For example if your site is at http://example.com/drupal uncomment and
# modify the following line:
# RewriteBase /drupal
#
# If your site is running in a VirtualDocumentRoot at
" title="http://example.com/,
">http://example.com/,
# uncomment the following line:
RewriteBase /masteroncology
# Rewrite URLs of the form 'x' to the form 'index.php?q=x'.
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
</IfModule>
# $Id: .htaccess,v 1.90.2.5 2010/02/02 07:25:22 dries Exp $
Prometto che se ne vengo a capo capendoci qualcosa scrivo una guida...
Una curiosità ... ma se metti
Una curiosità ... ma se metti solo questo (in pratica solo i clean url) nell'.htaccess funziona?
RewriteEngine onRewriteBase /masteroncology
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
PS Sei su linux o win?
Nada, neanche così....
Nada, neanche così.... :/
sempre e solo su linux!
Mhh ... una soluzione
Mhh ... una soluzione alternativa per provare a fare "ripartire" il sito è disabilitare i clean url seguendo queste istruzioni http://drupal.it/node/6448 e togliendo temporaneamente l'.htaccess.
Richiamandolo da web mi dava
Richiamandolo da web mi dava sempre E 500... ho cmq completato la procedura ma non è cambiato nulla...
Hai rinominato/rimosso
Hai rinominato/rimosso l'.htaccess temporaneamente prima di eseguire il file?
Ho visto che mi stanno
Ho visto che mi stanno modificando il file da aruba, evito di interferire ora e vedo cosa mi dicono.
Comunque prima l'avevo richiamato, cancellato l'htaccess e provato ad accedere, proprio in quest'ordine.
Ok, in caso comunque l'ordine
Ok, in caso comunque l'ordine di esecuzione è invertito, prima rinomini l'.htaccess poi esegui lo script.
Una discussione su come risolvere la questione c'è anche qui http://drupal.org/node/127351.
Ho visto che quelli di aruba
Ho visto che quelli di aruba hanno rinominato l'htaccess in ".htacces_moved_by_aruba" e sostiuito il tutto con
RewriteEngine onRewriteBase /masteroncology
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
per ora non funge ancora...