SlideShare une entreprise Scribd logo
1  sur  36
Troubleshooting Plone Ricardo Alves [email_address] Plone Conference 2009 - Budapest
What can go wrong?
Main Issues ,[object Object]
Instance not responding
Server IO errors
Unauthorized / security errors
Site Errors ,[object Object]
http://mysite/plonesite/error_log/manage_main
 
 
Site Errors ,[object Object]
INSTANCE_HOME/logs/event.log
Module zope.tal.talinterpreter, line 346, in interpret Module zope.tal.talinterpreter, line 745, in do_insertStructure_tal Module zope.tales.tales, line 696, in evaluate - URL: file:/Users/rsa/eurotux/udp/iporto/bundle/plone/CMFPlone/skins/plone_content/newsitem_view.pt - Line 41, Column 15 - Expression: <PythonExpr here.tag(scale='mini', css_class='newsImage')> - Names: {'container': <PloneSite at /plone>, 'context': <ATNewsItem at /plone/new-website-soon>, 'default': <object object at 0x395528>, 'here': <ATNewsItem at /plone/new-website-soon>, 'loop': {}, 'nothing': None, 'options': {'args': ()}, 'repeat': <Products.PageTemplates.Expressions.SafeMapping object at 0x6f4c0d0>, 'request': <HTTPRequest, URL=http://localhost:9095/plone/new-website-soon/newsitem_view>, 'root': <Application at >, 'template': <FSPageTemplate at /plone/newsitem_view used for /plone/new-website-soon>, 'traverse_subpath': [], 'user': <PropertiedUser 'admin'>} Module Products.PageTemplates.ZRPythonExpr, line 49, in __call__ - __traceback_info__: here.tag(scale='mini', css_class='newsImage') Module PythonExpr, line 1, in <expression> Module Products.ATContentTypes.content.newsitem, line 130, in tag AttributeError: 'NoneType' object has no attribute 'tag'
2009-10-28T16:43:46 WARNING LinguaPlone The thread number -1337921536 doesn't  have an associated request object. ------ 2009-10-28T16:45:00 INFO SignalHandler Caught signal SIGINT ------ 2009-10-28T16:45:00 INFO Z2 Shutting down ------ 2009-10-28T16:45:21 INFO ZServer HTTP server started at Wed Oct 28 16:45:21 2009 Hostname: 0.0.0.0 Port: 9095 ------ 2009-10-28T16:45:23 INFO Marshall libxml2-python not available. Unable to  register libxml2 based marshallers. ------ 2009-10-28T16:45:27 INFO ZEO.ClientStorage (4478) ClientStorage (pid=4478)  created RW/normal for storage: '1' ------ 2009-10-28T16:45:27 INFO ZEO.cache created temporary cache file '<fdopen>' ------ 2009-10-28T16:45:27 INFO ZEO.ClientStorage (4478) Testing connection  <ManagedClientConnection ('127.0.0.1', 9096)> ------ 2009-10-28T16:45:27 INFO ZEO.zrpc.Connection(C) (127.0.0.1:9096) received  handshake 'Z303'
Logging level ,[object Object]
INSTANCE_HOME/etc/zope.conf <eventlog> level info <logfile> path $INSTANCE/log/event.log level info  # &quot;CRITICAL&quot;, 'ERROR&quot;, WARN&quot;, &quot;INFO&quot;, # &quot;DEBUG&quot;, and &quot;ALL&quot; </logfile> </eventlog> <logger access> level WARN <logfile> path $INSTANCE/log/access.log format %(message)s </logfile> </logger>
Logging yourself ,[object Object],>>> import logging >>> logger = logging.getLogger('My package') >>> logger.log(logging.INFO, 'My message') >>> context.plone_log('My message') ,[object Object]
System logs $ tail -f /var/log/system.log ,[object Object],$ tail -f /var/log/messages $ tail -f /var/log/system.log
Instance not responding ,[object Object],$ telnet localhost 80  Trying ::1... telnet: connect to address ::1: Connection refused Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. GET /plone HTTP/1.1 HTTP/1.1 200 OK Server: Zope/(Zope 2.10.4-final, python 2.4.4, darwin) ZServer/1.1 Plone/3.1.7 Date: Wed, 28 Oct 2009 19:13:49 GMT Content-Length: 20541 Expires: Sat, 1 Jan 2000 00:00:00 GMT Content-Type: text/html;charset=utf-8 Content-Language: en <!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot; &quot; http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd &quot;> ...
Instance not responding $ telnet localhost 80  Trying ::1... telnet: connect to address ::1: Connection refused Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. GET /plone HTTP/1.1 HTTP/1.1 404 Not Found Server: Zope/(Zope 2.10.4-final, python 2.4.4, darwin) ZServer/1.1 Plone/3.1.7 Date: Wed, 28 Oct 2009 19:16:57 GMT Bobo-Exception-Line: 100 Content-Length: 812 Bobo-Exception-Value: See the server error log for details Content-Type: text/html; charset=iso-8859-15 Bobo-Exception-Type: NotFound Bobo-Exception-File: BaseRequest.py <html> <head><title>Zope</title></head> ...
Instance not responding ,[object Object],$ telnet localhost 81 Trying ::1... telnet: connect to address ::1: Connection refused Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. Z303
Instance not responding ,[object Object],$ INSTANCE_HOME/bin/zopectl fg ,[object Object],# Directive: debug-mode ... # #  Setting this to 'off' when Zope is in a production environment is #  encouraged, as it speeds execution (sometimes dramatically). # # Default: off # # Example: # debug-mode on
Instance not responding ,[object Object]
Elements from skin layers (templates, scripts, etc) can be edited while the server is running ,[object Object],[object Object]
recipe = plone.recipe.zope2instance
debug-mode = on
Zope Python console ,[object Object],$ INSTANCE_HOME/bin/zopectl debug Starting debugger (the name &quot;app&quot; is bound to the top-levelZope object) >>> app <Application at > >>> app.plone <PloneSite at /plone> >>> app.plone.portal_catalog(portal_type='News Item') [<Products.ZCatalog.Catalog.mybrains object at 0x669e270>] >>>
Zope Python console ,[object Object],>>> import rlcompleter >>> import readline >>> readline.parse_and_bind(&quot;tab: complete&quot;) >>> app.plone.portal_catalog.search<TAB PRESSED> ,[object Object],>>> from AccessControl.SecurityManagement import newSecurityManager >>> app.acl_users.getUserById('admin').__of__(app.acl_users) >>> newSecurityManager(None, user)
Zope Python console ,[object Object],>>> app._p_jar.sync() ,[object Object],>>> import transaction >>> transaction.commit() # Explicit commit >>> transaction.abort() # Transaction aborted >>> transaction.savepoint() # Savepoint >>> app._p_jar.sync() >>> app._p_jar.sync()
Python debugger ,[object Object],[object Object],try: return self.getField('photo').tag(self, **kwargs) except: import pdb, sys e, m, tb = sys.exc_info() pdb.post_mortem(tb) >>> import pdb; pdb.set_trace() INSTANCE_HOMT/plone/ATContentTypes/content/newsitem.py(133)tag()->None -> import pdb; pdb.set_trace( (Pdb) self <ATNewsItem at /plone/new-website-soon> (Pdb) self.getField('image') <Field image(image:rw)> (Pdb) self.getField('photo') >>> import pdb; pdb.set_trace()
Server IO errors ,[object Object],[object Object]
Check disc space at  /tmp  dir ,[object Object],[object Object]
“ Too many open files”
“ Read-only file system”
...
Debugging security issues ,[object Object],... Module Products.CMFPlone.browser.ploneview, line 111, in _initializeData Module plone.memoize.view, line 55, in memogetter Module plone.app.layout.globals.context, line 123, in object_title Module Products.CMFPlone.utils, line 158, in pretty_title_or_id Module Products.CMFPlone.utils, line 463, in base_hasattr Module Products.CMFPlone.utils, line 474, in safe_hasattr Module Shared.DC.Scripts.Bindings, line 184, in __getattr__ Unauthorized: You are not allowed to access 'Title' in this context

Contenu connexe

Tendances

Perl web frameworks
Perl web frameworksPerl web frameworks
Perl web frameworks
diego_k
 
Anatomy of a PHP Request ( UTOSC 2010 )
Anatomy of a PHP Request ( UTOSC 2010 )Anatomy of a PHP Request ( UTOSC 2010 )
Anatomy of a PHP Request ( UTOSC 2010 )
Joseph Scott
 

Tendances (20)

Get your teeth into Plack
Get your teeth into PlackGet your teeth into Plack
Get your teeth into Plack
 
Getting testy with Perl
Getting testy with PerlGetting testy with Perl
Getting testy with Perl
 
Memory Manglement in Raku
Memory Manglement in RakuMemory Manglement in Raku
Memory Manglement in Raku
 
Intermediate PHP
Intermediate PHPIntermediate PHP
Intermediate PHP
 
Introduction to PHP - Basics of PHP
Introduction to PHP - Basics of PHPIntroduction to PHP - Basics of PHP
Introduction to PHP - Basics of PHP
 
Web Apps in Perl - HTTP 101
Web Apps in Perl - HTTP 101Web Apps in Perl - HTTP 101
Web Apps in Perl - HTTP 101
 
Introduction to PHP
Introduction to PHPIntroduction to PHP
Introduction to PHP
 
Troubleshooting Puppet
Troubleshooting PuppetTroubleshooting Puppet
Troubleshooting Puppet
 
Key features PHP 5.3 - 5.6
Key features PHP 5.3 - 5.6Key features PHP 5.3 - 5.6
Key features PHP 5.3 - 5.6
 
PhpSpec extension points
PhpSpec extension pointsPhpSpec extension points
PhpSpec extension points
 
Php
PhpPhp
Php
 
BSDM with BASH: Command Interpolation
BSDM with BASH: Command InterpolationBSDM with BASH: Command Interpolation
BSDM with BASH: Command Interpolation
 
Perl web frameworks
Perl web frameworksPerl web frameworks
Perl web frameworks
 
07 Introduction to PHP #burningkeyboards
07 Introduction to PHP #burningkeyboards07 Introduction to PHP #burningkeyboards
07 Introduction to PHP #burningkeyboards
 
Smoking docker
Smoking dockerSmoking docker
Smoking docker
 
Nigel hamilton-megameet-2013
Nigel hamilton-megameet-2013Nigel hamilton-megameet-2013
Nigel hamilton-megameet-2013
 
Anatomy of a PHP Request ( UTOSC 2010 )
Anatomy of a PHP Request ( UTOSC 2010 )Anatomy of a PHP Request ( UTOSC 2010 )
Anatomy of a PHP Request ( UTOSC 2010 )
 
Webrtc mojo
Webrtc mojoWebrtc mojo
Webrtc mojo
 
Using PHP
Using PHPUsing PHP
Using PHP
 
Refactorización de aplicaciones PHP/Symfony2
Refactorización de aplicaciones PHP/Symfony2Refactorización de aplicaciones PHP/Symfony2
Refactorización de aplicaciones PHP/Symfony2
 

Similaire à Troubleshooting Plone

Bfg Ploneconf Oct2008
Bfg Ploneconf Oct2008Bfg Ploneconf Oct2008
Bfg Ploneconf Oct2008
Jeffrey Clark
 
Slides Aquarium Paris 2008
Slides Aquarium Paris 2008Slides Aquarium Paris 2008
Slides Aquarium Paris 2008
julien.ponge
 
How to? Drupal developer toolkit. Dennis Povshedny.
How to? Drupal developer toolkit. Dennis Povshedny.How to? Drupal developer toolkit. Dennis Povshedny.
How to? Drupal developer toolkit. Dennis Povshedny.
DrupalCampDN
 
Система рендеринга в Magento
Система рендеринга в MagentoСистема рендеринга в Magento
Система рендеринга в Magento
Magecom Ukraine
 

Similaire à Troubleshooting Plone (20)

Where's the source, Luke? : How to find and debug the code behind Plone
Where's the source, Luke? : How to find and debug the code behind PloneWhere's the source, Luke? : How to find and debug the code behind Plone
Where's the source, Luke? : How to find and debug the code behind Plone
 
Ext 0523
Ext 0523Ext 0523
Ext 0523
 
Adventures in infrastructure as code
Adventures in infrastructure as codeAdventures in infrastructure as code
Adventures in infrastructure as code
 
PhpBB meets Symfony2
PhpBB meets Symfony2PhpBB meets Symfony2
PhpBB meets Symfony2
 
Cooking with Chef
Cooking with ChefCooking with Chef
Cooking with Chef
 
Joomla! Day Chicago 2011 Presentation - Steven Pignataro
Joomla! Day Chicago 2011 Presentation - Steven PignataroJoomla! Day Chicago 2011 Presentation - Steven Pignataro
Joomla! Day Chicago 2011 Presentation - Steven Pignataro
 
It Works On Dev
It Works On DevIt Works On Dev
It Works On Dev
 
Teflon - Anti Stick for the browser attack surface
Teflon - Anti Stick for the browser attack surfaceTeflon - Anti Stick for the browser attack surface
Teflon - Anti Stick for the browser attack surface
 
When Good Code Goes Bad: Tools and Techniques for Troubleshooting Plone
When Good Code Goes Bad: Tools and Techniques for Troubleshooting PloneWhen Good Code Goes Bad: Tools and Techniques for Troubleshooting Plone
When Good Code Goes Bad: Tools and Techniques for Troubleshooting Plone
 
Debugging webOS applications
Debugging webOS applicationsDebugging webOS applications
Debugging webOS applications
 
Bfg Ploneconf Oct2008
Bfg Ploneconf Oct2008Bfg Ploneconf Oct2008
Bfg Ploneconf Oct2008
 
Download It
Download ItDownload It
Download It
 
Leveraging Continuous Integration For Fun And Profit!
Leveraging Continuous Integration For Fun And Profit!Leveraging Continuous Integration For Fun And Profit!
Leveraging Continuous Integration For Fun And Profit!
 
Drupal development
Drupal development Drupal development
Drupal development
 
Slides Aquarium Paris 2008
Slides Aquarium Paris 2008Slides Aquarium Paris 2008
Slides Aquarium Paris 2008
 
How to? Drupal developer toolkit. Dennis Povshedny.
How to? Drupal developer toolkit. Dennis Povshedny.How to? Drupal developer toolkit. Dennis Povshedny.
How to? Drupal developer toolkit. Dennis Povshedny.
 
Ph
PhPh
Ph
 
Introduction To Eclipse RCP
Introduction To Eclipse RCPIntroduction To Eclipse RCP
Introduction To Eclipse RCP
 
Система рендеринга в Magento
Система рендеринга в MagentoСистема рендеринга в Magento
Система рендеринга в Magento
 
A General Purpose Docker Image for PHP
A General Purpose Docker Image for PHPA General Purpose Docker Image for PHP
A General Purpose Docker Image for PHP
 

Dernier

EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 

Dernier (20)

The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 

Troubleshooting Plone