#1 2018-08-26 01:54:19

profh
Member
Registered: 2010-07-02
Posts: 159

TSQLHttpServer.Create raised "access violation" under CentOS7(64)

i have a server with mORMot running on Windows Server 2008, and it is stable and fast, many thanks to ab for the great work.

recently i would like to create a server running on CentOS7, i complied "04 - HTTP Client-Server" and changed Project04Server
permissions to "read and write", when i executed it,it raised "access violation" error.

i debugged it and found the breakpoint at "TSQLHttpServer.Create", maybe i missed something?

thanks!

Offline

#2 2018-08-26 15:07:20

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,206
Website

Re: TSQLHttpServer.Create raised "access violation" under CentOS7(64)

Difficult to state what happens with so few information...

Which version of FPC did you use?

Offline

#3 2018-08-27 02:17:10

profh
Member
Registered: 2010-07-02
Posts: 159

Re: TSQLHttpServer.Create raised "access violation" under CentOS7(64)

thanks for your quick reply,ab.

i used  newpascal and Lazarus trunk.
i also used the latest mORMot and SQLite3fpc files, and compiled with no error.

i think the error is not about mORMOt or pascal,perhaps it is about CentOS permissions,I have no idea.
i will reinstall CentOS and try it again.
thanks again.

Offline

#4 2018-08-27 09:23:21

profh
Member
Registered: 2010-07-02
Posts: 159

Re: TSQLHttpServer.Create raised "access violation" under CentOS7(64)

i debugged "04 - HTTP Client-Server" and got the messages as follow:

Exception class "ECrtSocket" at $00000000009E4F03 with message "OpenBind(0.0.0.0:8080,bind): CallServer=-1 99  [Cannot assign requested address]"

06fdf1b2069b9007.png

05ef744018f7f123.png

Last edited by profh (2018-08-27 09:29:58)

Offline

#5 2018-08-27 09:37:25

mpv
Member
From: Ukraine
Registered: 2012-03-24
Posts: 1,539
Website

Re: TSQLHttpServer.Create raised "access violation" under CentOS7(64)

1) Check nobody listen 8080 port (tomcat/apache) using command netstat -tulpn | grep LISTEN
2) Add permission to 8080

firewall-cmd --permanent --add-port=8080/tcp
firewall-cmd --reload

Offline

#6 2018-08-27 10:09:19

profh
Member
Registered: 2010-07-02
Posts: 159

Re: TSQLHttpServer.Create raised "access violation" under CentOS7(64)

thanks, mpv

i changed the port to 1234, and run:
firewall-cmd --permanent --add-port=1234/tcp
firewall-cmd --reload

it did not work.

Offline

#7 2018-08-27 10:28:11

profh
Member
Registered: 2010-07-02
Posts: 159

Re: TSQLHttpServer.Create raised "access violation" under CentOS7(64)

i am not good at Linux.
i compiled and executed "04 - HTTP Client-Server" successful on CentOS 7(64) about six month ago, but this time it does not work.
so i think the error is not about mORMOt or pascal, or it is about CentOS permissions, and i missed something.

Offline

#8 2018-08-27 11:08:59

profh
Member
Registered: 2010-07-02
Posts: 159

Re: TSQLHttpServer.Create raised "access violation" under CentOS7(64)

@ab and mpv,

i used Paralles Virtual Machine, and just changed the network adapter configure,it works now.

thanks a lot for your time.

Offline

Board footer

Powered by FluxBB