Lasso thinks my server name is computername.local

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

Lasso thinks my server name is computername.local

Diane Houdek
Okay so I don't have a domain name (no DNS entry for my machine set up,
the ethernet's temporarily disconnected too) and I'm just doing some
internal testing and rather than giving me back 127.0.0.1 or localhost
in response to [server_name] I get liselle.local as the server name on
my MacOS 10.4.3 laptop.  That's not going to fly when I need to set a
cookie (in fact it doesn't - ask Trevor!!) Why does this happen? What
can I do to tell Lasso that my IP address or localhost is the server
name?

Thanks!

Diane Houdek
[hidden email]

--
------------------------------
Lasso Support: http://support.omnipilot.com/
Search the list archives: http://www.listsearch.com/lassotalk.lasso
Manage your list subscription:  
http://www.listsearch.com/lassotalk.lasso?manage
Reply | Threaded
Open this post in threaded view
|

Re: Lasso thinks my server name is computername.local

Clive Bruton
I think this isn't Lasso, but Apache. You've probably connected  
somehow to http://liselle.local/ or had a redirect to that host name  
because it's in the Apache config. The most common cause of such a  
redirect is when you've tried to address a directory without a  
trailing slash, ie:

        http://127.0.0.1/folder

rather than:

        http://127.0.0.1/folder/

In the former case Apache will send back a redirect, that's probably  
where you are picking up the .local name. At a guess, anyway.


-- Clive


On 4 Jan 2006, at 04:56, Diane Houdek wrote:

> Okay so I don't have a domain name (no DNS entry for my machine set  
> up,
> the ethernet's temporarily disconnected too) and I'm just doing some
> internal testing and rather than giving me back 127.0.0.1 or localhost
> in response to [server_name] I get liselle.local as the server name on
> my MacOS 10.4.3 laptop.  That's not going to fly when I need to set a
> cookie (in fact it doesn't - ask Trevor!!) Why does this happen? What
> can I do to tell Lasso that my IP address or localhost is the server
> name?
>
> Thanks!
>
> Diane Houdek
> [hidden email]
>
> --
> ------------------------------
> Lasso Support: http://support.omnipilot.com/
> Search the list archives: http://www.listsearch.com/lassotalk.lasso
> Manage your list subscription:
> http://www.listsearch.com/lassotalk.lasso?manage


--
------------------------------
Lasso Support: http://support.omnipilot.com/
Search the list archives: http://www.listsearch.com/lassotalk.lasso
Manage your list subscription:  
http://www.listsearch.com/lassotalk.lasso?manage
Reply | Threaded
Open this post in threaded view
|

Re: Lasso thinks my server name is computername.local

Diane Houdek
In reply to this post by Diane Houdek
Thanks Clive for the ideas!

Actually there's nothing in the httpd.conf file because I've not
modified the original file in any way and I also did a search through
all the httpd files for liselle.local and couldn't find it in any of
them.  It's just the standard Apache file that comes with the installed
operating system (plus all of Apple's lovely patches!!).  The default
site in the Sites Admin has a URL of
http://liselle.local:80/SiteAdmin.0.LassoApp so its clear that Lasso has
this stored someplace. Hmmm...

I did some searching through the listsearch that some folks have
dissassembled the client headers to get a "host" equivalent to the old
host_name tag.  Maybe that's what we're after??

Diane
 
 
>>>[hidden email] 01/03/06 11:28 pm >>>
I think this isn't Lasso, but Apache. You've probably connected  
somehow to http://liselle.local/ or had a redirect to that host name  
because it's in the Apache config. The most common cause of such a  
redirect is when you've tried to address a directory without a  
trailing slash, ie:
 
http://127.0.0.1/folder 
 
rather than:
 
http://127.0.0.1/folder/ 
 
In the former case Apache will send back a redirect, that's probably  
where you are picking up the .local name. At a guess, anyway.
 
 
-- Clive

--
------------------------------
Lasso Support: http://support.omnipilot.com/
Search the list archives: http://www.listsearch.com/lassotalk.lasso
Manage your list subscription:  
http://www.listsearch.com/lassotalk.lasso?manage
Reply | Threaded
Open this post in threaded view
|

Re: Lasso thinks my server name is computername.local

Wade Maxfield
In reply to this post by Diane Houdek
>Thanks Clive for the ideas!
>
>Actually there's nothing in the httpd.conf file because I've not
>modified the original file in any way and I also did a search through
>all the httpd files for liselle.local and couldn't find it in any of
>them.  It's just the standard Apache file that comes with the installed
>operating system (plus all of Apple's lovely patches!!).  The default
>site in the Sites Admin has a URL of
>http://liselle.local:80/SiteAdmin.0.LassoApp so its clear that Lasso has
>this stored someplace. Hmmm...
>
>I did some searching through the listsearch that some folks have
>dissassembled the client headers to get a "host" equivalent to the old
>host_name tag.  Maybe that's what we're after??
>
>Diane
>
>
>>>>[hidden email] 01/03/06 11:28 pm >>>
>I think this isn't Lasso, but Apache. You've probably connected
>somehow to http://liselle.local/ or had a redirect to that host name
>because it's in the Apache config. The most common cause of such a
>redirect is when you've tried to address a directory without a
>trailing slash, ie:
>
>http://127.0.0.1/folder
>
>rather than:
>
>http://127.0.0.1/folder/
>
>In the former case Apache will send back a redirect, that's probably
>where you are picking up the .local name. At a guess, anyway.
>
>
>-- Clive
>
>--

liselle.local comes from the machine name you set in the Sharing
control panel of the OS.

You can overide this to be whatever you like in the terminal with:

sudo hostname myname.mydomain

- Wade

--
------------------------------
Lasso Support: http://support.omnipilot.com/
Search the list archives: http://www.listsearch.com/lassotalk.lasso
Manage your list subscription:  
http://www.listsearch.com/lassotalk.lasso?manage
Reply | Threaded
Open this post in threaded view
|

Re: Lasso thinks my server name is computername.local

m i l e s-4
In reply to this post by Diane Houdek
Diane,

I'll dive in here....in between client calls.

Take wade's suggestion to heart, change the name of the  
machine...however that's probably not what you want to do....

Im gathering what you want to do is something very similar to using  
an actual domain name instead of either the local loopback address or  
the computers local name.  There are several methods to doing what  
you want to do.  However if I may, using the standard loopback  
address isn't going to kill anything.  You're just not going to get a  
whole lot of variance with certain lasso random variables such as  
sessions.  So don't worry about the IP.  We're going to translate the  
IP to a private domain name.

What Im going to do is force your machine to use your machine's own  
hosts file as a temporary internal DNS!  It will only be local to  
your machine AND its completely reversible!  Actually in truth you  
will be able to use ANY domain name you like for testing purposes.  
Just remember however that the domain that you choose should be  
unique!  The kicker here is that you will NOT need an active internet  
connection, or a network connection at all!  The reason the domain  
you pick should be somewhat unique is because from this point forward  
if you attempt to go to a website that has the exact same URL, your  
local machine will be queried ONLY!  WHy ? because the local machine  
will think that the resource that's being asked for is LOCAL when in  
fact its not.  But I digress.  Just choose a domain name that works  
for you and you alone.  Remember this is only for testing purposes.

I do this all the time...so Im very familiar with it.

REQUIRED: BBEdit/TextWranger (either will do the trick).

1.) Open up your favorite editor (read that as BBEDIT, v6.0 or better  
OR TextWrangler which is free and will also do the trick!).

2.) From BBEdit/TextWrangler's OPEN HIDDEN (FILE > OPEN HIDDEN) menu  
selection, you'll get a dialogue window that allows you to navigate  
anywhere in the system.  And you'll note that you can navigate to ANY  
resource hidden or otherwise (hence the OPEN HIDDEN moniker!).  From  
here, navigate to the following:  yourvolume/etc/hosts.  It will be  
grayed out...you won't be able to select it YET.

3.) from the top of that dialogue window, select from the drop down  
menu ENABLE -> ALL FILES.  Now you should be able to select the hosts  
file.  Then hit the "OPEN" button.

What you're doing is opening up the HOSTS file that is resident on  
your machine...here's a good explanation of what the hosts file is  
and does...
http://accs-net.com/hosts/hostsforlinux.html

4.) When you open the file you should see something very similar to  
the following:

+++++++++++++++++++++

##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting.  Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1             localhost

+++++++++++++++++++++

Change nothing for the moment.  Just make sure that your file looks  
very similar to this.

5.) Now add a line right below the last line that looks something  
like this:

127.0.0.1 www.dianesfiles.com

And yes that's a < tab > in between the ip and the web url

6.) Save the file, and it should ask you for your admin username/
password. Enter it and you're good to go.

7.) Now again from OPEN HIDDEN menu in BBEdit/TextWrangler go to /etc/
httpd/httpd.conf and navigate all the way to the bottom of the file,  
you should see something that looks like:

#
# Use name-based virtual hosting.
#
# NameVirtualHost *:80
#
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for requests without a known
# server name.
#
# <VirtualHost *>
#     ServerAdmin [hidden email]
#     DocumentRoot /Library/WebServer/Documents/
#     ServerName yourvirtualhost.com
#     DirectoryIndex index.html
# </VirtualHost>

Change that to look like:

#
# Use name-based virtual hosting.
#
NameVirtualHost *:80
#
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for requests without a known
# server name.
#

<VirtualHost *>
      ServerAdmin [hidden email]
      DocumentRoot /Library/WebServer/Documents/dianesfiles
      ServerName www.dianesfiles.com
      DirectoryIndex index.lasso
</VirtualHost>

Make certain that the folder dianesfiles exists and that the file  
index.lasso exists within the folder.

8.) Close and save the document, you'll be prompted for your admin u/p.

9.) (and lastly)  Now open up your terminal application from your  
utilities folder and once open type the following command:

 > sudo apachectl graceful

You'll be prompted to ender a password, its asking for your admin  
password.  Enter it and hit return.

Now enter the following command exactly as written:

 > sudo kill -HUP `cat /var/run/lookupd.pid`

You will not be prompted for your admin u/p.  And yes those are HASH  
marks not quotations.  The key with the tilde on it.

10.) Phew...almost done...Open up your web browser and go to http://
www.dianesfiles.com/

Have fun.

That should solve your problem.

M i l e s

       $LASSO->MYSQL CONSULTANT & EVANGELIST FOR HIRE
   -don't know what 'LASSO' is ? - http://www.omnipilot.com/
------------------------------------------------------------
M i l e s                          [hidden email]
MagicMiles Software                         (415) 236 - 1344
Featuring: ToolboxEngine  - A Custom CMS    (415) 686 - 6164
http://www.lassoconsultant.com/   AIM/Yahoo/MSN:  magikmiles
------------------------------------------------------------
Creating custom content management systems for yoga, dance,
healing arts, & now real estate starting at just $65.00 a
month, incld: domain registration, web hosting, email and
webmail, and access to TOOLBOXENGINE!  A very robust tool.
------------------------------------------------------------



--
------------------------------
Lasso Support: http://support.omnipilot.com/
Search the list archives: http://www.listsearch.com/lassotalk.lasso
Manage your list subscription:  
http://www.listsearch.com/lassotalk.lasso?manage
Reply | Threaded
Open this post in threaded view
|

Re: Lasso thinks my server name is computername.local

Johan Solve
In reply to this post by Diane Houdek
2006/1/4, Diane Houdek <[hidden email]>:
> Okay so I don't have a domain name (no DNS entry for my machine set up,
> the ethernet's temporarily disconnected too) and I'm just doing some
> internal testing and rather than giving me back 127.0.0.1 or localhost
> in response to [server_name] I get liselle.local as the server name on
> my MacOS 10.4.3 laptop.

Just set UseCanonicalName to OFF in the apache config.


--
     Johan Sölve    [FSA Partner, Lasso Partner]
     Web Application/Lasso/FileMaker Developer
     MONTANIA SOFTWARE & SOLUTIONS
http://www.montania.se   mailto:[hidden email]
 (spam-safe email address, replace '-' with 'a')

--
------------------------------
Lasso Support: http://support.omnipilot.com/
Search the list archives: http://www.listsearch.com/lassotalk.lasso
Manage your list subscription:  
http://www.listsearch.com/lassotalk.lasso?manage
Reply | Threaded
Open this post in threaded view
|

Re: Lasso thinks my server name is computername.local

Johan Solve
In reply to this post by Diane Houdek
2006/1/4, m i l e s <[hidden email]>:

> Now enter the following command exactly as written:
>
>  > sudo kill -HUP `cat /var/run/lookupd.pid`

You don't have to restart lookupd when adding hosts, only when removing them.

And an easier way to restart it is this:
sudo killall -KUP lookupd


--
     Johan Sölve    [FSA Partner, Lasso Partner]
     Web Application/Lasso/FileMaker Developer
     MONTANIA SOFTWARE & SOLUTIONS
http://www.montania.se   mailto:[hidden email]
 (spam-safe email address, replace '-' with 'a')

--
------------------------------
Lasso Support: http://support.omnipilot.com/
Search the list archives: http://www.listsearch.com/lassotalk.lasso
Manage your list subscription:  
http://www.listsearch.com/lassotalk.lasso?manage
Reply | Threaded
Open this post in threaded view
|

Re: Lasso thinks my server name is computername.local

Johan Solve
In reply to this post by Diane Houdek
2006/1/4, Johan Solve <[hidden email]>:
> And an easier way to restart it is this:
> sudo killall -KUP lookupd

Oops, typo... Should of course be
sudo killall -HUP lookupd

--
     Johan Sölve    [FSA Partner, Lasso Partner]
     Web Application/Lasso/FileMaker Developer
     MONTANIA SOFTWARE & SOLUTIONS
http://www.montania.se   mailto:[hidden email]
 (spam-safe email address, replace '-' with 'a')

--
------------------------------
Lasso Support: http://support.omnipilot.com/
Search the list archives: http://www.listsearch.com/lassotalk.lasso
Manage your list subscription:  
http://www.listsearch.com/lassotalk.lasso?manage
Reply | Threaded
Open this post in threaded view
|

Re: Lasso thinks my server name is computername.local

Diane Houdek
In reply to this post by Diane Houdek
Thank you to Miles and Johan!! I think I get it now and will be able to
solve the problem. Always a helpful group!

Diane

--
------------------------------
Lasso Support: http://support.omnipilot.com/
Search the list archives: http://www.listsearch.com/lassotalk.lasso
Manage your list subscription:  
http://www.listsearch.com/lassotalk.lasso?manage