简体   繁体   English

在不同服务器上从Apache到Tomcat共享会话

[英]Share session from apache to tomcat on different servers

Hi I was wondering is it possible to share sessions from an apache server where drupal 6 is installed to a tomcat on another server? 嗨,我想知道是否可以从安装了drupal 6的apache服务器共享会话到另一台服务器上的tomcat? I want to authenticate a user to a tomcat webapp when they login to drupal. 我想在用户登录Drupal时向tomcat Webapp验证用户身份。 I've read documentation on it but they all require the the apache server and tomcat server to be on the same domain. 我已经阅读了文档,但是它们都要求apache服务器和tomcat服务器在同一域中。

In tomcat use 在tomcat中使用

memcached-session-manager

in apache/php, set memcached for sessions handling. 在apache / php中,将memcached设置为会话处理。

You need a memcached instance that both servers can access, or you can set-up a memcached server on either of the servers. 您需要两个服务器都可以访问的Memcached实例,或者您可以在其中两个服务器上设置一个Memcached服务器。

You will need php5-memcached or php-pecl-memcache depending on the linux repo. 您将需要php5-memcached或php-pecl-memcache,具体取决于Linux存储库。

You can use database for session handling. 您可以使用数据库进行会话处理。 The database should be accessible to both apache and tomcat. apache和tomcat都应该可以访问该数据库。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM