Forum

Posted by
vmos - July 2011
Good morning, we've been asked to put a 301 redirect on a site. Seems simple enough but the problem is we don't know the first thing about roxen.
We're more used to apache and the people that setup this particular server have vamoosed.

It's a debian lenny server and it appears to be running roxen server-5.0.403.

We need to redirect a single site, preferably with a 301. I found this code

<PAGE>
<redirect to=http newsite.com/ type=301″ />
</PAGE>

but have no idea where to put it. Can anyone point me in the right direction?
Posted by
Marcus Wellhardh - July 2011
You can place the redirect tag in the page that should be redirected, see this link for documentation:

  http://docs.roxen.com/roxen/5.1/web_developer_manual/protocol/redirect.tag

If you like to redirect all requests to another server, I suggest using the "Redirect Module" that can be added in the administration interface after selecting the appropriate site. Then configure a redirect pattern on the Settings tab like:

  [permanent]  /.*  http://newsite.com/
Posted by
vmos - July 2011
well, that's one of the problems. We don't have the login details for the control panel, I was looking for a way to do this serverside.
Posted by
Marcus Wellhardh - July 2011
You can reset the password if you have access to the server.

The Administrative Interface password is crypted and located at configurations/_configinterface/settings/<user>_uid
An example:

<map>
  <str>permissions</str> : <a> <str>Everything</str> </a>
  <str>real_name</str>   : <str>Administrator</str>
  <str>password</str>    : <str>AaBbCcDd123456.</str>
  <str>name</str>        : <str>www</str>
</map>

The easiest way to reset Administrative Interface password is to run pike with the following arguments and change the "password" ("AaBbCcDd123456" in the example above) string:

 $ pike -e 'write(crypt("foo")+"\n")'
D8yo4FSiSbbDE

Finally, copy paste the encrypted password into the password value field.

I think you also could remove the crypted password, i.e. enter the empty string, then you can log in with the username and the empty password.

A server restart might be needed also.
Posted by
Martin Stjernholm - July 2011
The easiest way to add a new login to the admin interface is to go to the server-X.Y.Z directory and run:

bin/roxen bin/create_configif.pike -a

It'll ask you for username and password.
1
Search this thread: