Run application code on sharepoint server start-up

Hi, 
I am building a sharepoint 2010 application (server APIs, c#) that sends notification messages via TCP from sharepoint server to server X whenever a file changes in a sharepoint library. I have my code in ItemUpdated() method
of my class inherited from SPItemEvenReceiver.
Apart from notification messages I need to send keep alive messages to server X every T seconds. These keep alives have to be sent after the application is installed on the sharepoint server and whenever it's up and running. I do it by listening to FeatureActivated event
of SPFeatureReceiver.
So when the feature is activated on a site collection, my "init" code runs and starts sending keep alive messages.
When either of the following events happen:
1) IIS application pool gets recycled every day at 1:50 am (default setting), or 2) server is powered down, then powered up
my "init" code is not executed (because there is no "Feature activate" event), and keep alives are not sent.
Is there a way of receiving of some sort of event in my application that would fire in both cases, so I could run my "init" code? Or maybe, some deployment option that would allow to run the "init" code tight after sharepoint server started
(or application pool recycled)?
Thanks

the reason it's unreliable is because you're designing based on the assumption that SharePoint will "somehow / magically" let your app know when it's "running" (which is itself somewhat of a nebulous definition, since SP consists of a
*lot* of moving parts, such as many instances of IIS, timer applications, multiple servers, etc).
Instead, take the events, log them to a queue (MSMQ, custom service app / database, whatever)... then implement a circuit breaker design for pushing, and a backup design for polling the data.
i'm not sure quite what your intentions are with the keepalive, and you can do wahtever you like, I'm just telling you that the approach will eventually bite you.
Scott Brickey
MCTS, MCPD, MCITP
www.sbrickey.com
Strategic Data Systems - for all your SharePoint needs

Similar Messages

  • JDev will not run application local, Weblogic fails to start.

    Has anyone seen this when running an app in JDev?
    WLS Start Mode=Development
    CLASSPATH=.;C:\Program Files\Java\jre6\lib\ext\QTJava.zip
    PATH=C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files\Reflection;C:\Program Files\MKS\IntegrityClient\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\system32\WindowsPowerShell\v1.0;C:\WINDOWS\Options\Installs\Engcustom;C:\Program Files\Microsoft SQL Server\80\Tools\Binn\;c:\Program Files\Microsoft SQL Server\90\Tools\binn\;C:\Program Files\Common Files\Roxio Shared\9.0\DLLShared\;C:\Program Files\Common Files\Roxio Shared\DLLShared\;C:\WINDOWS\system32\WindowsPowerShell\v1.0;C:\Program Files\Microsoft SQL Server\90\DTS\Binn\;C:\Program Files\Microsoft SQL Server\90\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files\QuickTime\QTSystem\
    * To start WebLogic Server, use a username and *
    * password assigned to an admin-level user. For *
    * server administration, use the WebLogic Server *
    * console at http:\\hostname:port\console *
    starting weblogic with Java version:
    The system cannot find the path specified.
    Starting WLS with line:
    \bin\java ...
    The system cannot find the path specified.
    Process exited.
    This is a new installation of JDev and does this when running the Webcenter tutorial.
    I have deleted both the system folder and the DefaultDomain folder and restarted JDev. Error still occurs. It looks like some env vars are not being set properly, but this is out of the box scripts.
    Any clue would be appreciated.

    It is set to where my projects are. I also set JAVA_HOME to the jdk folder and now I get this at runtime:
    *** Using port 7101 ***
    "C:\Documents and Settings\vince.holt\Application Data\JDeveloper\system11.1.1.3.37.56.60\DefaultDomain\bin\startWebLogic.cmd"
    [waiting for the server to complete its initialization...]
    The system cannot find the path specified.
    JAVA Memory arguments:
    WLS Start Mode=Development
    CLASSPATH=
    PATH=%CommonProgramFiles%\Microsoft Shared\Windows Live;C:\Program Files\Reflection;C:\Program Files\MKS\IntegrityClient\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\system32\WindowsPowerShell\v1.0;C:\WINDOWS\Options\Installs\Engcustom;C:\Program Files\Microsoft SQL Server\80\Tools\Binn\;c:\Program Files\Microsoft SQL Server\90\Tools\binn\;C:\Program Files\Common Files\Roxio Shared\9.0\DLLShared\;C:\Program Files\Common Files\Roxio Shared\DLLShared\;C:\WINDOWS\system32\WindowsPowerShell\v1.0;C:\Program Files\Microsoft SQL Server\90\DTS\Binn\;C:\Program Files\Microsoft SQL Server\90\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files\QuickTime\QTSystem\
    * To start WebLogic Server, use a username and *
    * password assigned to an admin-level user. For *
    * server administration, use the WebLogic Server *
    * console at http:\\hostname:port\console *
    starting weblogic with Java version:
    java version "1.6.0_18"
    Java(TM) SE Runtime Environment (build 1.6.0_18-b07)
    Java HotSpot(TM) Client VM (build 16.0-b13, mixed mode)
    Starting WLS with line:
    C:\Oracle\Middleware\jdk160_18\bin\java -Dweblogic.Name= -Djava.security.policy=\server\lib\weblogic.policy -Djavax.net.ssl.trustStore=C:\Oracle\Middleware\wlserver_10.3\server\lib\DemoTrust.jks -Doracle.adfm.usemds=true -Dweblogic.nodemanager.ServiceEnabled=true
    Usage: java [-options] class [args...]
    (to execute a class)
    or java [-options] -jar jarfile [args...]
    (to execute a jar file)
    where options include:
    -client     to select the "client" VM
    -server     to select the "server" VM
    -hotspot     is a synonym for the "client" VM [deprecated]
    The default VM is client.
    -cp <class search path of directories and zip/jar files>
    -classpath <class search path of directories and zip/jar files>
    A ; separated list of directories, JAR archives,
    and ZIP archives to search for class files.
    -D<name>=<value>
    set a system property
    -verbose[:class|gc|jni]
    enable verbose output
    -version print product version and exit
    -version:<value>
    require the specified version to run
    -showversion print product version and continue
    -jre-restrict-search | -jre-no-restrict-search
    include/exclude user private JREs in the version search
    -? -help print this help message
    -X print help on non-standard options
    -ea[:<packagename>...|:<classname>]
    -enableassertions[:<packagename>...|:<classname>]
    enable assertions
    -da[:<packagename>...|:<classname>]
    -disableassertions[:<packagename>...|:<classname>]
    disable assertions
    -esa | -enablesystemassertions
    enable system assertions
    -dsa | -disablesystemassertions
    disable system assertions
    -agentlib:<libname>[=<options>]
    load native agent library <libname>, e.g. -agentlib:hprof
    see also, -agentlib:jdwp=help and -agentlib:hprof=help
    -agentpath:<pathname>[=<options>]
    load native agent library by full pathname
    -javaagent:<jarpath>[=<options>]
    load Java programming language agent, see java.lang.instrument
    -splash:<imagepath>
    show splash screen with specified image
    Process exited.
    I sent the output and SetDomainEnv.cmd, StartWeblogic.cmd files to Chris as requested. Maybe he can help.
    This is a fresh out-of-the-box installation of JDev and the first project attempted to run. Is there some other env vars that need to be set on Windows?

  • Error Message Running Application From MS Terminal Server. Ora-01019

    Dear folks
    I had this problem recently and this is the solution to it.
    Applies to:
    Oracle Server - Standard Edition - Version: 10.2.0.2
    Information in this document applies to any platform.
    Goal
    #1. How to solve the ORA-01019 when running an application from terminal services without
    administrative privileges?
    Solution
    There is a MS security option that has to be enabled for the non-administrative users.
    Please grant "Create global objects" to the non-administrative privileges as indicated at:
    http://technet2.microsoft.com/WindowsServer/en/Library/ba351dd0-aaf5-4e1e-b7dc-10a514842a0a1033.mspx
    "You can configure this security setting by opening the appropriate policy and expanding the
    console tree as such: Computer Configuration\Windows Settings\Security Settings\Local
    Policies\User Rights Assignment\"
    and retry

    Caused By: Error at line:1 col:2  Got character[0] expected a valid XML character
    The character in line 1 col 2 is not a valid XML character. Is the line 1 the XML prolog?
    <?xml version=“1.0” encoding=“UTF-8” ?>

  • How to to publish php web application with Mysql as database in sharepoint server 2013

    I Have done a PHP web Application which uses html, css,javascript, php, mysql, ajax. now i want to publish this web application in my sharepoint server 2013. I want this site in my company intranet. How can i do this? 

    You can host that site in web server. 
    Use SharePoint page viewer webpart to show content from your PHP site on sharepoint page
    http://office.microsoft.com/en-in/sharepoint-server-help/page-viewer-web-part-HA010024045.aspx
    http://office.microsoft.com/en-in/sharepoint-foundation-help/display-a-web-page-on-a-sharepoint-page-by-adding-the-page-viewer-web-part-HA101857182.aspx

  • Missing applications for the SharePoint Web Services site in IIS

    We have SharePoint 2013 server farm and in one of the server missing service applications/virtual directories.
    Under IIS, “SharePoint Web Services" site including an Application Pool and SharePoint Web Services Root is available, but no applications for the SharePoint Service Applications, all applications (security token service, topology ..) virtual directories
    are missing/removed/deleted.
    Can we re-provision only service applications on local SharePoint server, local server only not in any other servers in the server farm?
    Thank You.
    -RK

    Hi RK,
    Please check if services has been started on this server via CA > System Settings 
    > Manager services on server > change server to the current one.
    Is there other application server in your farm? Please test the issue on other servers.
    Regards,
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected] .
    Rebecca Tu
    TechNet Community Support

  • Run perl script on remote server

    Hello
    I have 2 servers, server 1 and server2.
    I have a perl script on server2 and I want to execute that perl script so my code is like
    $command= { param($p1,$p2) cmd /c test.pl $p1 $p2 }
    Invoke-Command -session $sesion -ScriptBlock $command -ArgumentList 1,2
    session is already created with server2 from server1. 
    perl script kept on server2 spawn another cmd which interacts with server3.
    When I run above code that perl script start executing but it stays in executing step for infinite time..as per observation, I have found that it stucks when it tried to spawn another cmd which interacts with server3 from server2.
    How can I handle this?

    Second hop restriction and some issue in the perl script that prevents it from honoring the error.
    Run script interactively to test results.
    Enter-PsSession $session
    Type your command and see if you see an error.
    \_(ツ)_/

  • Its Urgent! J2EE Server Started but the Application is not running?

    J2EE server starts ok, I deployed the application successfully but when I open the URL http://localhost:8000 to start the application in browser it shows errors e.g
    Error: 500
    Internal Servlet Error:
    java.lang.NoSuchMethodError
    at com.sun.web.security.SecurityInterceptor.setSSLAttributes(SecurityInterceptor.java:56)
    at com.sun.web.security.SecurityInterceptor.preInvoke(SecurityInterceptor.java:83)
    at org.apache.tomcat.core.ServiceInvocationHandler.preInvoke(ServletWrapper.java:615)
    at org.apache.tomcat.core.ServletWrapper.handleInvocation(ServletWrapper.java:531)
    at org.apache.tomcat.core.ServletWrapper.handleRequest(ServletWrapper.java:378)
    at org.apache.tomcat.core.Context.handleRequest(Context.java:644)
    at org.apache.tomcat.core.ContextManager.service(ContextManager.java:440)
    at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:144)
    at org.apache.tomcat.service.TcpConnectionThread.run(TcpEndpoint.java:310)
    at java.lang.Thread.run(Thread.java:484)
    Please Help me its very Urgent

    I deployed the application successfully, J2ee server started successfully but when I open the browser and try to run the application or view the welcome page it shows the above mentioned error.

  • Sharepoint server search service error starting

    hi,
    we have two server for team foundation server.
    server1 installed: Team foundation server 2012, Sharepoint 2013, MSSQL 2008 r2 on windows server 2012 standart
    server2 installed: team foundation build server on windows server 2012 standart
    sharepoint search service can not started on server1.
    displayed message to the following (after start link clicked on "manage services on server link"):
    starting the search service on a server must be done within the context of a search service application. click OK to go to the Manage service applications page where you can create a new Search service application or select a search service application and
    modify its topology.
    the page forwarded to serviceapplications.aspx url after I clicked OK.
    new button list options: App Management Service, Business Data Connectivity Service, Secure Store Service. I can not seen search service application.
    but there is sharepoint server search 15 service and with tfsfarm account running on computer services list.
    Get-SPServiceInstance cmd on powershell result to the following:
    Role : None
    DedicatedWebFrontEndServer : 
    DefaultIndexLocation : D:\SP2013\Office Server\Applications
    IndexLocations : {}
    Description : Index content and serve search queries
    ManageLink : Microsoft.SharePoint.Administration.SPActionLi nk
    ProvisionLink : Microsoft.SharePoint.Administration.SPActionLi nk
    UnprovisionLink : Microsoft.SharePoint.Administration.SPActionLi nk
    SystemService : False
    MinutesBetweenCrawlSchedulingAttempts : 5
    CrawlComponents : {}
    AdminComponents : {}
    Components : {}
    RequiresAdministrationService : True
    TypeName : SharePoint Server Search
    Server : SPServer Name=xxx
    Service : SearchService Name=OSearch15
    Instance : 
    Roles : 
    Hidden : False
    CanUpgrade : True
    IsBackwardsCompatible : True
    NeedsUpgradeIncludeChildren : False
    NeedsUpgrade : False
    UpgradeContext : Microsoft.SharePoint.Upgrade.SPUpgradeContext
    Name : 
    DisplayName : 
    Id : c632644a-84f9-41b3-9757-410704764a2e
    Status : Disabled
    Parent : SPServer Name=xxxx
    Version : 680572
    Properties : {}
    Farm : SPFarm Name=SharePoint_Config
    UpgradedPersistedProperties : {}
    Start-SPServiceInstance c632644a-84f9-41b3-9757-410704764a2e cmd on powershell:
    TypeName : SharePoint Server Search
    Description : Index content and serve search queries
    Id : c632644a-84f9-41b3-9757-410704764a2e
    Server : SPServer Name=xxxx
    Service : SearchService Name=OSearch15
    Role : None
    Status : Provisioning
    status provisioning a long time (after Get-SPServiceInstance c632644a-84f9-41b3-9757-410704764a2e cmd)
    stsadm -o osearch -action start cmd:
    stsadm : 'start' action failed. Additional information: Service is offline
    stsadm -o osearch -action stop cmd:
    Warning: The SharePoint Server Search service that was enabled on this server will be 
    uninstalled and all index files for all Search Applications will be deleted.
    I waited 24-48 hours but don't seen result message on powershell and don't stopped script.
    I runned sharepoint configuration wizard but dont resolved problem.

    Do you have a full version of SharePoint (not Foundation one)?
    Try to create Search from PowerShell command line. There are a lot of guides in Internet regarding this question.

  • Initiall SharePoint Server 2013 setup -- unable to manage new User Profile Service Application

    During initial farm setup, creating an initial User Profile Service Application works fine.  However, once it's created, I cannot 'manage' it through the Manage Service Applications page in central
    admin.
    I get a generic error (Sorry, something went wrong / unexpected error) with a correlation ID that doesn't seem to match any ULS log entries. (Yes, I merged logs from all machines in the farm.)
    A Windows event log entry says:
    A failure was reported when trying to invoke a service application: Endpoint Failure
    Also frequent errors in ULS logs:  (see below)
    UserProfileApplicationNotAvailableException     
    User Profile Application      Proxy failed to retrieve partitions from User Profile Application: Micro…
    SPDistributedCache DataCacheException
    I did notice that the file 'ProfileService.svc does not exist in SharePoint's web services app at the URL you see in the error. (below)
    I also found it interesting that the event log error shows 1 active endpoint and 3 failed endpoints.  I have 2 WFEs and 2 app servers.  But I'm only trying to get the user profile service app running on the application
    servers.  I have deleted and recreated this service app several times under various names (deleted/recreated its app pool as well) and wonder if these other failed endpoints could be orphans from previous instances...
    Any thoughts on how I might successfully create this service application?  I've already been Binging my head against a wall long enough that I would have been better off reinstalling the entire farm...  I may still
    do that.
    FYI, my farm came from a slipstreamed SP1 install package, and received the July CU after several other things were already configured, including the already-failed UP service application.
    Log Name:      Application 
    Source:        Microsoft-SharePoint Products-SharePoint Foundation 
    Date:          8/8/2014 6:11:54 PM 
    Event ID:      8313 
    Task Category:
    Topology 
    Level:         Error 
    Keywords:       
    User:          xyz\sp_farm
    Computer:      spapp1.xyz.local 
    Description: 
    A failure was reported when trying to invoke a service application: EndpointFailure 
    Process Name: w3wp 
    Process ID: 4284 
    AppDomain Name: /LM/W3SVC/560632691/ROOT-1-130519915587486075 
    AppDomain ID: 2 
    Service Application Uri: urn:schemas-microsoft-com:sharepoint:service:3f215b603e634a629875945488863f75#authority=urn:uuid:9f338b52a7b049b193d8f8dc514fdadd&authority=https://spapp1:32844/Topology/topology.svc 
    Active Endpoints: 1 
    Failed Endpoints:3 
    Affected Endpoint:
    http://spapp1:32843/3f215b603e634a629875945488863f75/ProfileService.svc 
    Event Xml: 
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> 
      <System> 
        <Provider Name="Microsoft-SharePoint Products-SharePoint Foundation" Guid="{6FB7E0CD-52E7-47DD-997A-241563931FC2}" /> 
        <EventID>8313</EventID> 
        <Version>15</Version> 
        <Level>2</Level> 
        <Task>13</Task> 
        <Opcode>0</Opcode> 
        <Keywords>0x4000000000000000</Keywords> 
        <TimeCreated SystemTime="2014-08-08T23:11:54.738080000Z" /> 
        <EventRecordID>14550</EventRecordID> 
        <Correlation ActivityID="{02A1AC9C-1125-6026-E124-A52653003266}" /> 
        <Execution ProcessID="4284" ThreadID="16072" /> 
        <Channel>Application</Channel> 
        <Computer>spapp1</Computer> 
        <Security UserID="S-1-5-21-499312637-3451022336-10712144539-44056" /> 
      </System> 
      <EventData> 
        <Data Name="string0">EndpointFailure</Data> 
        <Data Name="string1">w3wp</Data> 
        <Data Name="int2">4284</Data> 
        <Data Name="string3">/LM/W3SVC/560632691/ROOT-1-130519915587486075</Data> 
        <Data Name="int4">2</Data> 
        <Data Name="string5">urn:schemas-microsoft-com:sharepoint:service:3f215b603e634a629875945488863f75#authority=urn:uuid:9f338b52a7b049b193d8f8dc514fdadd&amp;authority=https://spapp1:32844/Topology/topology.svc</Data> 
        <Data Name="int6">1</Data> 
        <Data Name="int7">3</Data> 
        <Data Name="string8">http://spapp1:32843/3f215b603e634a629875945488863f75/ProfileService.svc</Data> 
      </EventData> 
    </Event> 
    Log Name:      Application 
    Source:        Microsoft-SharePoint Products-SharePoint Foundation 
    Date:          8/8/2014 6:51:04 PM 
    Event ID:      8313 
    Task Category: Topology 
    Level:         Error 
    Keywords:       
    User:          VANTAGE\sp_farm 
    Computer:      spapp1.vantage.local 
    Description: 
    A failure was reported when trying to invoke a service application: EndpointFailure 
    Process Name: OWSTIMER 
    Process ID: 8472 
    AppDomain Name: DefaultDomain 
    AppDomain ID: 1 
    Service Application Uri: urn:schemas-microsoft-com:sharepoint:service:3f215b603e634a629875945488863f75#authority=urn:uuid:9f338b52a7b049b193d8f8dc514fdadd&authority=https://spapp1:32844/Topology/topology.svc 
    Active Endpoints: 1 
    Failed Endpoints:3 
    Affected Endpoint:
    http://spapp2:32843/3f215b603e634a629875945488863f75/ProfileService.svc 
    Event Xml: 
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> 
      <System> 
        <Provider Name="Microsoft-SharePoint Products-SharePoint Foundation" Guid="{6FB7E0CD-52E7-47DD-997A-241563931FC2}" /> 
        <EventID>8313</EventID> 
        <Version>15</Version> 
        <Level>2</Level> 
        <Task>13</Task> 
        <Opcode>0</Opcode> 
        <Keywords>0x4000000000000000</Keywords> 
        <TimeCreated SystemTime="2014-08-08T23:51:04.938901900Z" /> 
        <EventRecordID>14596</EventRecordID> 
        <Correlation /> 
        <Execution ProcessID="8472" ThreadID="17360" /> 
        <Channel>Application</Channel> 
        <Computer>spapp1.vantage.local</Computer> 
        <Security UserID="S-1-5-21-499312637-3451022336-10712144539-44056" /> 
      </System> 
      <EventData> 
        <Data Name="string0">EndpointFailure</Data> 
        <Data Name="string1">OWSTIMER</Data> 
        <Data Name="int2">8472</Data> 
        <Data Name="string3">DefaultDomain</Data> 
        <Data Name="int4">1</Data> 
        <Data Name="string5">urn:schemas-microsoft-com:sharepoint:service:3f215b603e634a629875945488863f75#authority=urn:uuid:9f338b52a7b049b193d8f8dc514fdadd&amp;authority=https://spapp1:32844/Topology/topology.svc</Data> 
        <Data Name="int6">1</Data> 
        <Data Name="int7">3</Data> 
        <Data Name="string8">http://spapp2:32843/3f215b603e634a629875945488863f75/ProfileService.svc</Data> 
      </EventData> 
    </Event> 
    20:22:31.94 SharePoint Portal Server User Profiles cm6y High  
    User Profile Application Proxy failed to retrieve partitions from User Profile Application: Microsoft.Office.Server.UserProfiles.UserProfileApplicationNotAvailableException: UserProfileApplicationNotAvailableException_Logging
    :: UserProfileApplicationProxy.ApplicationProperties ProfilePropertyCache does not have 6cd1c1f0-5874-4f8e-9c0a-ed1aff342048     at Microsoft.Office.Server.Administration.UserProfileApplicationProxy.get_ApplicationProperties()    
    at Microsoft.Office.Server.Administration.UserProfileApplicationProxy.get_PartitionIDs()     at Microsoft.Office.Server.Administration.UserProfileApplicationProxy.IsAvailable(SPServiceContext serviceContext)  
    20:22:38.16 SharePoint Portal Server User Profiles d22b High  
    Failure retrieving application ID for User Profile Application Proxy 'User Profile Service Application': Microsoft.Office.Server.UserProfiles.UserProfileApplicationNotAvailableException: UserProfileApplicationNotAvailableException_Logging
    :: UserProfileApplicationProxy.ApplicationProperties ProfilePropertyCache does not have 6cd1c1f0-5874-4f8e-9c0a-ed1aff342048     at Microsoft.Office.Server.Administration.UserProfileApplicationProxy.get_ApplicationProperties()    
    at Microsoft.Office.Server.Administration.UserProfileApplicationProxy.get_AppID()  
    20:22:44.25 SharePoint Foundation DistributedCache ah24v High  
    [Forced due to logging gap, cached @ 08/08/2014 20:22:38.16, Original Level: Verbose] DistributedCacheClient TransportProperties- ChannelInitializationTimeout '{0}', ConnectionBufferSize '{1}',                                  
    MaxBufferPoolSize '{2}', MaxBufferSize '{3}', MaxOutputDelay '{4}',ReceiveTimeout '{5}'.  
    20:22:55.26 SharePoint Foundation DistributedCache ah24w Unexpected  
    Unexpected Exception in SPDistributedCachePointerWrapper::InitializeDataCacheFactory for usage 'DistributedViewStateCache' - Exception 'Microsoft.ApplicationServer.Caching.DataCacheException: ErrorCode<ERRCA0017>:SubStatus<ES0006>:There
    is a temporary failure. Please retry later. (One or more specified cache servers are unavailable, which could be caused by busy network or servers. For on-premises cache clusters, also verify the following conditions. Ensure that security permission has been
    granted for this client account, and check that the AppFabric Caching Service is allowed through the firewall on all cache hosts. Also the MaxBufferSize on the server must be greater than or equal to the serialized object size sent from the client.). Additional
    Information : The client was trying to com...  

    Thanks for the suggestion.  I performed the service restarts, and then an iisreset an the two web servers, and the application server that does not run the services.  Finally, I ran iisreset on the application server that does run the services.
    After performing those steps, I still cannot manage the user profile service application.
    ULS log at the time of the attempt contains User Profile Application Proxy errors (in my original post) and am also noticing the following error:
    08:15:21.17 SharePoint Foundation General ajlz0 High Getting Error Message for Exception System.Web.HttpUnhandledException
    (0x80004005): Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> Microsoft.Office.Server.UserProfiles.UserProfileApplicationNotAvailableException:
    This User Profile Application's connection is currently not available. The Application Pool or User Profile Service may not have been started. Please contact your administrator.     at Microsoft.SharePoint.Portal.UserProfiles.AdminUI.ProfileAdminPage.get_CurrentApplicationProxy()    
    at Microsoft.SharePoint.Portal.UserProfiles.AdminUI.ManageUserProfileServiceApplicationBase.OnPreRender(EventArgs e)     at System.Web.UI.Control.PreRenderRecursiveInternal()    
    at System.Web.UI.Page.ProcessRequestMain(Boolean
    includeStagesBeforeAsyncPoint, Boolean
    includeStag...  

  • Is there any way to get an application to load automatically on server start?

    We're trying to implement a load-balancing mechanism between FMS hosts in a virtual "farm".  The mechanism we're using is to have the FMSs periodically send "load" data (along with a timestamp) to an application server.  That server will then use that load information and timestamp to detect when an FMS server has gone down and to make stream assignments to FMSs.
    Right now, I've implemented this code via a setInterval() in live/main.asc.  I've added a "return false" to Application.onAppStop() to (according to the docs, I haven't tested this yet) keep the server from shutting down an idle instance.  So I've left with a "chicken and egg" issue: how do I get the interval running before the first request hits the application (and forces the load of the application)?  I've tried putting the setInterval in onAppStart() and as a global.  In both cases, it only gets executed after application is loaded.
    So, is there any way to force an application to load (via a config file parameter or local command-line)?

    Hi,
    I am sorry i have not read the full details what you wrote, but if you are looking for loading of application on start of the server, there is a configuration tag in application.xml called loadonstartup and by default it is set to false. Set it to true to enable it and all the apps will be loaded on server start.
    alternatively , you can make an application.xml inside the application folder and set this tag to true, to have this applied only to a particular application,
    Also, the fms admin console can launch a new instance of an app without any connection being made initially.
    Thank you !

  • Fatal error when trying to backup SharePoint server (Failed to set request to pause search application)

    I have powershell script that is used to backup SharePoint server. It was working correctly until last week. I found this error message indicate that search application cannot be paused. I don't know what happen and what should I do to solve this issue.
    Please help me find solution for this.
    [20/1/2557 18:53:53] FatalError: Object Search Service Application failed in event OnBackup. For more information, see the spbackup.log or sprestore.log file located in the backup directory.
    InvalidOperationException: Failed to set request to pause search application

    Hi,
    According to your post, my understanding is that you got an error when you backup your SharePoint Server.
    You can do the steps below, then check whether it works.
    Look for any One-time timer job  for Backup/Restore and delete it (From Central Administration > Monitoring > Review Job Definitions)
    Clear the timer cache following the below link:
    http://blogs.msdn.com/b/jamesway/archive/2011/05/23/sharepoint-2010-clearing-the-configuration-cache.aspx
    Run the below command from the SharePoint Management Shell:
    $ssa = Get-SPEnterpriseSearchServiceApplication –Identity <SearchServiceApplicationName>
    Suspend-SPEnterpriseSearchServiceApplication -Identity $ssa
    Once the above steps are completed successfully start the full farm backup from the Central Administration > Backup and Restore > Farm Backup
    Once backup is completed run the below command to resume the SSA
    $ssa = Get-SPEnterpriseSearchServiceApplication –Identity <SearchServiceApplicationName>
    Resume-SPEnterpriseSearchServiceApplication -Identity $ssa
    Thanks & Regards,
    Jason
    Jason Guo
    TechNet Community Support

  • How to execute a java application once the server starts

    I have created a java application which executes correctly. I want this application to execute everytime I start my server. I have modified my web.xml as shown below
    <servlet>
    <servlet-name>SendEmail</servlet-name>
    <servlet-class>
    com.allcorp.alliance.tdocs.servlets.SendEmail</servlet-class>
    <init-param>
    <param-name>config</param-name>
    <param-value>/WEB-INF/struts-config.xml</param-value>
    <load-on-startup>1</load-on-startup>
    </init-param>
    </servlet>
    I have extended the class with HttpServlet. When I start the server, I get the message saying the class is being initializing but it does not execute. I want the application to execute. Any idea what I need to do.

    BalusC wrote:
    Implement ServletContextListener and run the appplication on creation of the ServletContext.Well i understand implementation of ServletContextListener and by overiding contextInitialized(ServletContextEvent se) accordingly can solve the problem.
    but you need to consider two cases here first
    1).ServletContextListener is not supported by all container especially the minor onces which does not support Servlet 2.3 specification.
    2).OP does not have any idea of how to use a Servlet first if you can see he had written his intialization code in the main method.Now how can you expect him to create a listener..... :)
    I hope there are no hard issues on what i said this time.
    *@OP*
    My friend the bad news is that you need to spend bit of time learning about servlets.U'd not be writing intialization code inside a main rather you'd be doing it inside public void init(ServletConfig config) method.
    by making <load-on-startup><!--value</load-on-startup> in web.xml enables Servlet container to call init method at the time of deployment of the web application else where it'd call the init method whenever servlet encounters first request from a client.
    package com.allcorp.alliance.tdocs.servlets;
    import java.util.*;
    import javax.mail.*;
    import javax.mail.internet.*;
    import javax.servlet.http.*;
    import javax.servlet.*;
    import javax.activation.*;
    * @author ssa3z
    * TODO To change the template for this generated type comment go to
    * Window - Preferences - Java - Code Style - Code Templates
    public class SendEmail extends HttpServlet{
    public void init(ServletConfig config) {
        // SUBSTITUTE YOUR EMAIL ADDRESSES HERE!!!
        String to = "[email protected]";
        String from = "[email protected]";
        // SUBSTITUTE YOUR ISP'S MAIL SERVER HERE!!!
        String host = "smtp.allstate.com";
        // Create properties, get Session
        Properties props = new Properties();
       // If using static Transport.send(),
      // need to specify which host to send it to
      props.put("mail.smtp.host", host);
      // To see what is going on behind the scene
      props.put("mail.debug", "true");
      Session session = Session.getInstance(props);
      try {
         // Instantiatee a message
         Message msg = new MimeMessage(session);
         //Set message attributes
         msg.setFrom(new InternetAddress(from));
         InternetAddress[] address = {new InternetAddress(to)};
         msg.setRecipients(Message.RecipientType.TO, address);
         msg.setSubject("Test E-Mail through Java");
         msg.setSentDate(new Date());
         // Set message content
         msg.setText("This is a test of sending a " +"plain text e-mail through Java.\n" +"Here is line 2.");
         //Send the message
         Transport.send(msg);
      }catch (MessagingException mex) {
        mex.printStackTrace();
    } Hope this might help :)
    REGARDS,
    RaHuL

  • Scale out sharepoint server search to index server and Microsoft SharePoint Foundation Web Application to new server

    Hi
    in my single server these below service are running:
    SharePoint Server Search 
    User Profile Service 
    Microsoft SharePoint Foundation Web Application
    here how i scale out  Microsoft SharePoint Foundation Web Application  to another server
    and  SharePoint Server Search  to new index server.
    adil

    Check here to see how to add servers to the farm:
    http://technet.microsoft.com/en-us/library/cc261752(v=office.15).aspx
    What Inderjeet meant was that if you chose to install SharePoint as a single server instead of a complete farm, you won't be able to add servers to the farm at a later time. You can check if this is the case by checking the registry key he mentioned. If
    that is indeed the case, there's nothing to it but reinstall the farm.
    So that is why you never should choose the single server option, it locks you in and limits future options, while choosing to install sharepoint as a complete farm it's still perfectly acceptable to host it on a single server.
    Kind regards,
    Margriet Bruggeman
    Lois & Clark IT Services
    web site: http://www.loisandclark.eu
    blog: http://www.sharepointdragons.com

  • Real-Time Application doesn't run; source code works fine

    The short version is I'm programming a cRIO and apparently the RT code isn't running after being deployed and I can't figure out why. This is further complicated that I'm doing all this remotely and I don't have direct access to the unit since I'm 500 miles away. I'm working through a couple of other guys who know some LabVIEW, but neither works at the site so they have to explicitely travel out there every time I have a bright idea.
    I was out there a few weeks ago. During this time I created a simple cRIO code, since I'm new to cRIO, that allowed the user to move a control and change a graph. It worked fine, but I should note it did not have an FPGA component. After that I worked on the real code, which reads some sensors, displays the results on a UI and logs the results. This did have FPGA. I used it in the LabVIEW environment and it worked fine, but I ran out of time before I could complete a release version and deploy the RT as a compiled application. I sent them the release version later, my contact deployed it but got network stream errors when running the UI.
    After hours of looking at network problems and sending over debug versions, I tried creating a log on the RT level so I could see what was going on. The log doesn't even open, even if it's the first command in the code. I pored through the forums and found http://forums.ni.com/t5/LabVIEW/cRIO-Troubleshooting-creation-and-deployment-of-startup/td-p/1956475... which took me in a new direction.
    I had my contact use the RT debug console and when he pulls up the RT front panel, it shows a broken run arrow. He clicks it and nothing happens -- no running, no bug list. If he pulls up the bug list manually, it's empty. Again the RT works fine if you run it through LabVIEW and not as a compiled real-time application. He also noticed that the Open FPGA VI was grayed out on the block diagram. No other icons are.
    So the problem appears to be that the compiled RT application is getting some kind of error but not telling me what it is, and it seems to be related to opening the FPGA. I've recompiled the FPGA and RT. I've had him recompile the RT himself, but not the FPGA because it would take hours. He's downloading everything correctly to the cRIO. The RT is set to run automatically. He's rebooting the cRIO every time he deploys the RT. They have LabVIEW on a computer there but it doesn't have the right drivers to run the code from the LV environment. I'm resisting having them install the dirvers because downloading big files is complicated there due to security restrictions and a lousy network connection at a remote site. Besides that doesn't solve the problem of the RT executable not running the same as the source code, which according to the thread above appears to be a thing.
    The latest thing I'm trying is that I sent him instructions for how to build a source distribution from the project I sent and try deploying that to the cRIO. Even if that works I'm not sure that's an acceptable solution because I assume running the VI rather than the EXE is slower, and they need speed on this project.
    I simply have no idea where to go from here. I probably need to get direct acess to the cRIO and I might be able to convince them to ship it to me so I can figure this out, but I'm not sure where I'd even start other than the standard voodoo debugging of "try stuff at random until something works". I'm open to suggestions if anyone has managed to solve this before.
    Code snippet of the first part of the project is attached, though I'm not sure how much good it will do. I'm really stumped and the client is getting frustrated with how much of the budget is going to fix this.
    Solved!
    Go to Solution.
    Attachments:
    RTMainSnippet.png ‏623 KB

    Have you checked the cRIO error log? Usually I'd access it through the LabVIEW project (right-click on the target, don't remember the exact menu options and I don't have the RT toolkit installed on this machine to check), but it must be stored somewhere on the cRIO as well, although I don't know if it's in a human-readable format.
    Which cRIO are you using? What exactly do you mean by "debug console"? (This may be related to the cRIO - the newer ones have video out, although I don't know if that's what you're referring to.) With a broken run arrow, you won't get an error list unless you're running in the development environment.
    Have you confirmed that the software installed on the cRIO matches the version you're using for development, including patch level? Get someone to connect to the cRIO with Measurement and Automation Explorer, and get a list of the software installed on the cRIO.
    Sounds like the ability to connect with a remote debugger would be helpful here, if you can get the right drivers installed on the machine with LabVIEW that's connected to the cRIO. Make sure all driver versions match what you're using. Any chance you could then do a remote desktop connection from your work site to the remote LabVIEW machine?

  • Application Server Starting and then Stopping

    For some reason my NSP server is starting with MMC, but then after about a minute it stops again. Please see the log files below. It seems to be a database problem but I don't know how to fix it...
    dev_w0
    trc file: "dev_w0", trc level: 1, release: "700"
    *  ACTIVE TRACE LEVEL           1
    *  ACTIVE TRACE COMPONENTS      all, MJ

    B Fri Jun 20 23:50:24 2008
    B  create_con (con_name=R/3)
    B  Loading DB library 'C:\usr\sap\NSP\DVEBMGS00\exe\dbsdbslib.dll' ...
    B  Library 'C:\usr\sap\NSP\DVEBMGS00\exe\dbsdbslib.dll' loaded
    B  Version of 'C:\usr\sap\NSP\DVEBMGS00\exe\dbsdbslib.dll' is "700.08", patchlevel (0.19)
    B  New connection 0 created
    M sysno      00
    M sid        NSP
    M systemid   560 (PC with Windows NT)
    M relno      7000
    M patchlevel 0
    M patchno    23
    M intno      20050900
    M make:      multithreaded, ASCII
    M pid        4928
    M
    M  kernel runs with dp version 202(ext=109) (@(#) DPLIB-INT-VERSION-202)
    M  length of sys_adm_ext is 360 bytes
    M  ***LOG Q0Q=> tskh_init, WPStart (Workproc 0 4928) [dpxxdisp.c   1288]
    I  MtxInit: 30000 0 0
    M  DpSysAdmExtCreate: ABAP is active
    M  DpSysAdmExtCreate: VMC (JAVA VM in WP) is not active
    M  DpShMCreate: sizeof(wp_adm)          5280     (880)
    M  DpShMCreate: sizeof(tm_adm)          3351072     (16672)
    M  DpShMCreate: sizeof(wp_ca_adm)          1200     (60)
    M  DpShMCreate: sizeof(appc_ca_adm)     1200     (60)
    M  DpCommTableSize: max/headSize/ftSize/tableSize=500/8/528040/528048
    M  DpShMCreate: sizeof(comm_adm)          528048     (1048)
    M  DpFileTableSize: max/headSize/ftSize/tableSize=0/0/0/0
    M  DpShMCreate: sizeof(file_adm)          0     (72)
    M  DpShMCreate: sizeof(vmc_adm)          0     (1076)
    M  DpShMCreate: sizeof(wall_adm)          (22440/34344/56/100)
    M  DpShMCreate: sizeof(gw_adm)     48
    M  DpShMCreate: SHM_DP_ADM_KEY          (addr: 04C80040, size: 3950264)
    M  DpShMCreate: allocated sys_adm at 04C80040
    M  DpShMCreate: allocated wp_adm at 04C81978
    M  DpShMCreate: allocated tm_adm_list at 04C82E18
    M  DpShMCreate: allocated tm_adm at 04C82E48
    M  DpShMCreate: allocated wp_ca_adm at 04FB5068
    M  DpShMCreate: allocated appc_ca_adm at 04FB5518
    M  DpShMCreate: allocated comm_adm at 04FB59C8
    M  DpShMCreate: system runs without file table
    M  DpShMCreate: allocated vmc_adm_list at 05036878
    M  DpShMCreate: allocated gw_adm at 050368B8
    M  DpShMCreate: system runs without vmc_adm
    M  DpShMCreate: allocated ca_info at 050368E8
    M  DpShMCreate: allocated wall_adm at 050368F0
    Y  *** ERROR => ztta/diag_area is 64000. [sapinit.c    325]
    Y  *** ERROR => ztta/diag_area adjusted to 128000 (minimum value). [sapinit.c    327]
    Y  *** ERROR => ztta/cua_area is 90000. [sapinit.c    963]
    Y  *** ERROR => ztta/cua_area adjusted to 250000. [sapinit.c    967]
    X  EmInit: MmSetImplementation( 2 ).
    X  MM diagnostic options set: 0
    X  <ES> client 0 initializing ....
    X  Using implementation flat
    M  <EsNT> Memory Reset disabled as NT default
    X  ES initialized.

    M Fri Jun 20 23:50:25 2008
    M  ThInit: running on host PackardBell
    M  calling db_connect ...

    C  DBSDBSLIB : version 700.08, patch 0.019 (Make PL 0.23)
    C  MAXDB shared library (dbsdbslib) patchlevels (last 10)
    C    (0.019) UPDSTAT optimized (note 870327)
    C    (0.010) MaxDB DBSL patch collection 1 2005 (note 850830)
    C    (0.009) New stream compression available with LVC 7.6.0 b12 (note 835809)
    C    (0.008) Support of SDBUPDEXCL (note 847616)
    C    (0.005) Switch stream compression on/off (note 835809)
    C    (0.005) ITAB stream handling optimized (note 835809)


    C  Loading SQLDBC client runtime ...
    C  SQLDBC SDK Version : SQLDBC.H  7.6.0    BUILD 002-121-083-965
    C  SQLDBC Library Version : libSQLDBC 7.6.0    BUILD 018-123-113-357
    C  SQLDBC client runtime is MaxDB 7.6.0.018 CL 113357
    C  INFO : SQLOPT= -I 0 -t 0
    C  Try to connect (DEFAULT) on connection 0 ...
    C  *** ERROR => Connect to database failed, rc = -10757 (XUSER error (the USERKEY is unknown))
    [dbsdbsql.cpp 98]
    C  Try to connect (SQLOPT) on connection 0 ...
    C  *** ERROR => Connect to database failed, rc = -10709 (Connection failed (RTE:Database name is missing))
    [dbsdbsql.cpp 118]
    B  ***LOG BV3=> severe db error -10709    ; work process is stopped [dbsh#1 @ 1195] [dbsh    1195 ]
    B  ***LOG BY2=> sql error -10709 performing CON [dblink#3 @ 431] [dblink  0431 ]
    B  ***LOG BY0=> Connection failed (RTE:Database name is missing) [dblink#3 @ 431] [dblink  0431 ]
    M  ***LOG R19=> ThInit, db_connect ( DB-Connect 000256) [thxxhead.c   1391]
    M  in_ThErrHandle: 1
    M  *** ERROR => ThInit: db_connect (step 1, th_errno 13, action 3, level 1) [thxxhead.c   9995]

    M  Info for wp 0

    M    stat = 4
    M    reqtype = 1
    M    act_reqtype = -1
    M    rq_info = 0
    M    tid = -1
    M    mode = 255
    M    len = -1
    M    rq_id = 65535
    M    rq_source = 255
    M    last_tid = 0
    M    last_mode = 0
    M    semaphore = 0
    M    act_cs_count = 0
    M    control_flag = 0
    M    int_checked_resource(RFC) = 0
    M    ext_checked_resource(RFC) = 0
    M    int_checked_resource(HTTP) = 0
    M    ext_checked_resource(HTTP) = 0
    M    report = >                                        <
    M    action = 0
    M    tab_name = >                              <
    M    vm = V-1

    M  *****************************************************************************
    M  *
    M  *  LOCATION    SAP-Server PackardBell_NSP_00 on host PackardBell (wp 0)
    M  *  ERROR       ThInit: db_connect
    M  *
    M  *  TIME        Fri Jun 20 23:50:25 2008
    M  *  RELEASE     700
    M  *  COMPONENT   Taskhandler
    M  *  VERSION     1
    M  *  RC          13
    M  *  MODULE      thxxhead.c
    M  *  LINE        10180
    M  *  COUNTER     1
    M  *
    M  *****************************************************************************

    M  PfStatDisconnect: disconnect statistics
    M  Entering TH_CALLHOOKS
    M  ThCallHooks: call hook >ThrSaveSPAFields< for event BEFORE_DUMP
    M  *** ERROR => ThrSaveSPAFields: no valid thr_wpadm [thxxrun1.c   720]
    M  *** ERROR => ThCallHooks: event handler ThrSaveSPAFields for event BEFORE_DUMP failed [thxxtool3.c  260]
    M  Entering ThSetStatError
    M  ThIErrHandle: do not call ThrCoreInfo (no_core_info=0, in_dynp_env=0)
    M  Entering ThReadDetachMode
    M  call ThrShutDown (1)...
    M  ***LOG Q02=> wp_halt, WPStop (Workproc 0 4928) [dpnttool.c   327]

    Ok I eventually figured it out... The SAP Application Server starts the database using the XUSER authentication - For some reason my system lost all settings for this.
    In order to recreate, I had to use the command prompt and use the XUSER command.
    Firstly "XUSER LIST" lists all user keys - I had none.
    I then needed to set the default XUSER:
    XUSER -d NSP -u SAPNSP,<password>
    <password> is the password for the user specified
    Then I created the "c" key:
    XUSER -d NSP -U c -u SAPNSP,<password>
    The reason I set up the "c" XUSER is because I noticed that in "\usr\sap\NSP\DVEBMGS00\exe\" there is a batch file used to start the DB - "strdbs.cmd". Inside this file it uses "c" as the user key in order to set the state of the DB.
    After all of that it worked again...

Maybe you are looking for

  • Mail in OS Mavericks HELP!!! Why do some of my emails not send despite the sent sound playing?

    Dear Mac Community I have a MacBook Pro running OS 10.9.1 and everything is fully updated. I use the Mac Mail programme to send and receive Gmail emails as I have done for many years. Recently, I started to notice a worrying problem. Every 10 or 20 e

  • ITunes wont connect to internet

    Hello Apple Users! I am new here hopefully this will resolve all my issues! I've been trying to connect to the iTunes Store but i keep getting the same error message "iTunes could not connect to the iTunes store. The network connection timed out." He

  • Converting Planned Order to Purchase Requisition

    Is their configuration that can automatically convert planned order to purchase requisition based on information like planned delivery time, etc.?  Or, does the conversion of planned order have to be done via MD15 either manually or by batch job?

  • Is it possible to change the orientation with the Ken Burns effect?

    Friends, I would like to change the orientation of the Ken Burns effect for a particular photo that I've insterted into a movie.  In other words, the KBE crops the image in landscape mode -- I'd like to crop it in portrait mode (which is how the phot

  • Skype Unlimited World Subscription Payment Refused

    If you have failed to pay due to credit card expiry or any other reason and once Skype has tried to charge you and they fail and cancel your subscription - you can't do anything to renew your subscription - or can you? I have wasted three days and um