Bitnami Lamp Stack Need Vhost Help

I have installed my app in a Bitnami Lamp stack subdirectory off of the root.  When I try to access it using abc.com/sub it doesn't work.  But if I put in a test program in abc.com/abc.php it works fine.   I need this stack to have 4 sites on it.  

How do I set it up so I can 4 vhosts?

The first vhost is only a test and isn't propogated.  The rest will be added after the first vhost is completed.

Thanks,
sharingsunshineAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Julian HansenCommented:
Do you want to setup a vhost or an alias?

abc.com/sub/...
or
sub.abc.com

If the first then you can setup an Alias in your httpd.conf file like this
<IfModule alias_module>
  Alias /sub "/path/to/your/folder"	
  ...
</IfModule>

Open in new window

Restart Apache and you should be able to access the /sub from abc.com
sharingsunshineAuthor Commented:
I put in your code
 </IfModule>

<IfModule alias_module>
  Alias /sub "/opt/bitnami/apache2/htdocs/thp"
</IfModule>

Open in new window

but it still doesn't work.  I get this message

https://gyazo.com/4ec58304f85fa6750c8b39cb91b1a56f

Open in new window


this is using the subdirectory prefix and without it I get the bitnami startup screen.

Please advise
sharingsunshineAuthor Commented:
I just noticed the /sub.   I changed it to /thp and restarted Apache but still no help.
IT Pros Agree: AI and Machine Learning Key

We’d all like to think our company’s data is well protected, but when you ask IT professionals they admit the data probably is not as safe as it could be.

Julian HansenCommented:
I don't understand the message - that looks like a URL
sharingsunshineAuthor Commented:
it's a screenshot of the error.
Julian HansenCommented:
That error has nothing to do with aliases - the address you typed in was not found.

What is the full url you are using does the root domain of this URL work?
Julian HansenCommented:
Or are you asking how to setup Apache so it will serve pages for a specific domain?

There are two issues here

1. abc.com resolves and loads but you want to be able to access abc.com/sub where /sub is located in a different location on the system
2. abc.com does not resolve and you want to setup a virtual host so that your Apache installation handles requests for abc.com
sharingsunshineAuthor Commented:
It's really a yes and no.  

1.  abc.com is the ip number currently and when used it resolves to the bitnami welcome page.  Yes, I want to access /sub and its contents.  Eventually, I will need number 2.

2.  No, since it does resolve but only to the bitnami welcome page.  When I have all the domains on the server I will need virtual hosts for each domain.

When I put in abc.com/sub I get the error message I posted above.

So ultimately I need to know where to put the content for each individual domain and how to access it.
Julian HansenCommented:
The error message you posted says server not found so there is something wrong at the DNS level in terms of routing it to the right place. You need to solve that before you can solve the virtual folder issue.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
sharingsunshineAuthor Commented:
I don't agree.  When I put in the ip  number it defaults in the url browser bar to http//1.1.1.1/sub

It seems the colon (:) being left out is why the server not found message is showing up.

Also, as I mentioned it resolves to the bitnami welcome page it is only when I add the /sub to the url that causes the issue.
Julian HansenCommented:
It seems the colon (:) being left out is why the server not found message is showing up.
I am going on the information you have given us - you posted a screenshot showing a server not found - the reasons are not really important as that is the information you chose to share with us - it indicates ... the server was not found.

To go from that to trying to work out why aliases are not working is not really going to help until the server not found issue has been resolved.

Can you show us a screen shot of what the browser looks like when you enter abc.com/sub AND abc.com resolves to the server address on which the Bitnami stack is installed.
sharingsunshineAuthor Commented:
Thanks for the help.
Julian HansenCommented:
You are welcome.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux

From novice to tech pro — start learning today.