Htaccess error

Having problem with error. Uploaded as txt and renamed as .htaccess

I am trying to use redirects for all pages that I have deleted to make Google happy. Getting this message :

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

Well you haven’t posted the “more information about the error from the server error log” - so this is a shot in the dark:

Make sure the text file uses LF linebreaks instead of CRLF. After logging into a shell, you can use the dos2unix tool to convert the file if necessary. Also in shell you can edit the .htaccess live without having to do a file transfer.

Otherwise if there is a mistake with the directives, you may need to post the contents.

Being new to DreamHost, I don’t know where the error log is. I am use to a different type of cpanel. on my former server, I could just type my web address and /cpanel/ to get to all my info. needless to say, I am lost . . .
I logged in to my ‘Dashboard’, but don’t see a link I need . . .
Can you steer me in the right direction? Thanks. Roberta

I may not be using the correct syntex or may be missing something since I have over 100 pages to redirect. Do I need some spacing between each link?

This is how I have written the file:

Options +FollowSymlinks
RewriteEngine on
rewriterule ^about.html(.)$$1 [r=301,nc]
rewriterule ^jewelry/bracelet.html(.
)$$1 [r=301,nc]

on my goodness, I tried something different and it worked!
It was so simple!
no fuss-no muss, just this:

Redirect /about.html
Redirect /jewelry/butterflyMINI.gif

I always try everything the hard way LOL

What would be really great would be if all urls that were gone or mistyped
could be redirected to one page by using one redirect. say to index.html.
So I would not have to write each url seperately.
Is there such an animal?

[quote]What would be really great would be if all urls that were gone or mistyped
could be redirected to one page by using one redirect. say to index.html.
So I would not have to write each url seperately.
Is there such an animal?[/quote]

You don’t want that. Really. :slight_smile: It’ll confuse search engines rather badly, since your site will suddenly be telling the search engine that everything exists.

Since it sounds like you’re using a static web site, you can create a HTML file on your domain called “missing.html”. Once you’ve created this file, its contents will be displayed when a user requests a page or file that doesn’t exist.

That is a good point. I didn’t realize it would be such a problem to have so many dead links. The web design person I have been working with told me that if the links are dead I needed to redirect them to anywhere because google looks badly on dead links and it reflects negatively on my rating. When I moved to DreamHost a short time ago, I decided to Spring clean my site as it was a massive nightmare with a lot pages and directories I no longer needed. I reused the urls that I could but didn’t have use for over 100 of them. I am thinking that I should have bought a new domain name and started out fresh and just parked the one I have now to keep it from being used by someone else… hum, maybe that is a thought to explore further.

Thanks for your response.

Hi BF, how about posting some error from the server error log and hopefully, someone might be able to find a way for this.

I asked before, please, where is the error log, and how do I get there?

Via SSH: /home/username/logs/

Is this the entire .htaccess and did you save it as plain text?

Options +FollowSymlinks
RewriteEngine on
rewriterule ^about.html(.*)$$1 [r=301,nc]
rewriterule ^jewelry/bracelet.html(.*)$$1 [r=301,nc]

No, It didn’t not look like that.
I changed it to this new one. Hoping it will work for Google now.
it is ftp as a txt file ASCII TEXT

the new one is not RewriteEngine
Here are the first few lines:

Redirect /about.html
Redirect /jewelry/aboutus.html
Redirect /AMTgardens/myjune.html
Redirect /artBrace.html
Redirect /chainEC5.html
Redirect /Cocinero.html

That works too :slight_smile: Wildcards and grep can be really tricky. I hate to spell out my redirects, but sometimes you have to.

Remember ‘index.html’ is a default index page/file name, so you need not specify it - and it will look a lot cleaner. ie:

Redirect /about.html
Can be just:
Redirect /about.html

Or even simpler: since the target URL is on your own domain, you can use a relative URL:

I always thought you need to point out index.html. Agreed, it will come in handy when you do troubleshooting in the future. Less characters, less things to troubleshoot. :slight_smile: