Solved thread

This post is marked as solved. If you think the information contained on this thread must be part of the official documentation, please contribute submitting a pull request to its repository.

Windows to Centos Server

Hello,

i am working locally on a Windows xampp system, but my live system is a Centos OS.

Now nothing is working on Centos, but still on Windows, i can't login into my account:

You don't have access to this module: private

Do i have to choose same server OS? Maybe a session problem?

Rgds Stefan

Never use different environments for development and production. That's the #1 reason for failures.

Create a virtual machine (vmware/virtualbox). on your windows, install CentOS (or any nix of your choice), and run the necessary services inside that.

Other than that, you provide little to no info about your problem. What account do you want to access? Is the error message generated by you? By Phalcon? By PHP? By the OS?



18.6k
edited Aug '17

Hello @lajosbencz,

the login from my staging. i am using Vokuro as my base system, but the login mechanism is still the same, i haven't changed anything there.

The "You don't have access to this module: private" message is generated by the BaseController.php of Vokuro

https://github.com/phalcon/vokuro/blob/master/app/controllers/ControllerBase.php

I found out that the line 33, $identity = $this->auth->getIdentity(); is NULL, so i think that it has something to to with the sessions, but i really don't know.

I think that i change my server from Centos to Windows, that shouldn't be a problem.

Thx for help :-)

Rgds Stefan

FYI, windows is not the best choice for PHP development, you'll encounter more bugs and nuisance that way.... (not to mention the OS is not for free)

Firing up your own VM will solve your dev/prod mismatch, and its safe because you wont wreck your remote system.

But its up to You! x)



18.6k

I have a parallel Linux Mint Installation on my notebook, i will check it there.

So, i have a VM on my Macbook, will also check it there.

Thx again for your infos @lajosbencz



3.8k

Last time I used PHP, PHP installed different default modules in Windows. You need to phpinfo(); on both systems and make the configuration the same.

The latest releases are often different. This either means coding for the older release or moving the most up to date system back a step.

Xampp is the worst part of your config. I ran PHP without Xampp across Windows and Linux with no problems. About 2 million PHP developers did that for may years when Windows was popular. I tried helping friends who used xampp but xampp overrode everything, making a complete mess of configurations and locations. Xampp is not compatible with anything, not even other installs of xampp. My advice to everyone looking at xampp. Just say NO!



3.8k

A note on dual boot to Linux. You can use that to start moving to Linux full time. Most of the applications on windows have parallel applications on Linux. Set up an NTFS shared partition for your data. start the move.

As an example, I work on projects where management insists on Microsoft Office .docx documents. Almost everyone uses LibreOffice to produce the .docx files. Libreoffice runs the same on Windows and Linux. You can stay in the Linux session for longer.



18.6k
Accepted
answer

Hello @petermoo and @lajosbencz,

in my case it was the notation. In Windows i wrote Searchcriteria in the joins, but the correct notation is SearchCriteria.

Stupid, but now it works and i changed all my codes to Ubuntu now.

Thx for your help :-)