Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7807821
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T02:58:30+00:00 2026-06-02T02:58:30+00:00

I’m trying to integrate a project into maven having two components – client (written

  • 0

I’m trying to integrate a project into maven having two components – client (written in silverlight) and server (written in java). The server side is fully maven compatible but I’m having issues running msbuild using maven. I get the following access denied error

Embedded error: Cannot run program “C:\WINDOWS\Microsoft.NET\Framework\v4.0.3031
9\msbuild” (in directory “C:\workspace\something\client”): CreateProcess error=5,
Access is denied

Machine: Windows XP
shell: git bash and cmd

pom.xml:

        <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
      <modelVersion>4.0.0</modelVersion>
      <groupId>x</groupId>
      <artifactId>client</artifactId>
      <version>0.0.1-SNAPSHOT</version>
      <packaging>pom</packaging>
      <name>client</name>
     <build>
       <plugins>
        <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>exec-maven-plugin</artifactId>
            <configuration>
                <executable>${msbuild.path}</executable>
            </configuration>
            <executions>
                 <execution>
                 <id>clean</id>
                 <phase>clean</phase>
                 <configuration>
                <arguments>
                <argument>/t:Clean</argument>
                </arguments>
             </configuration>
             <goals>
                 <goal>exec</goal>
             </goals>
             </execution>
             <execution>
             <id>build</id>
             <phase>compile</phase>
             <configuration>
                 <arguments>
                <argument>/t:some.sln</argument>
                 </arguments>
             </configuration>
                 <goals>
                    <goal>exec</goal>
                 </goals>
             </execution>
           </executions>
        </plugin>
      </plugins>
     </build>
    </project>

error:

        $ mvn compile -Dmsbuild.path=C:/WINDOWS/Microsoft.NET/Framework/v4.0.30319/msbu
    ild -e
    + Error stacktraces are turned on.
    [INFO] Scanning for projects...
    [INFO] ------------------------------------------------------------------------
    [INFO] Building client
    [INFO]    task-segment: [compile]
    [INFO] ------------------------------------------------------------------------
    [INFO] [exec:exec {execution: build}]
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Command execution failed.

    Embedded error: Cannot run program "C:\WINDOWS\Microsoft.NET\Framework\v4.0.3031
    9\msbuild" (in directory "c:\workspace\something\client"): CreateProcess error=5,
     Access is denied
    [INFO] ------------------------------------------------------------------------
    [INFO] Trace
    org.apache.maven.lifecycle.LifecycleExecutionException: Command execution failed
    .
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
    ultLifecycleExecutor.java:719)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLi
    fecycle(DefaultLifecycleExecutor.java:556)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defau
    ltLifecycleExecutor.java:535)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan
    dleFailures(DefaultLifecycleExecutor.java:387)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen
    ts(DefaultLifecycleExecutor.java:348)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi
    fecycleExecutor.java:180)
            at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
            at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
            at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
            at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:6
    0)
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
    java:39)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
    sorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:597)
            at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
            at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
            at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)

            at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
    Caused by: org.apache.maven.plugin.MojoExecutionException: Command execution fai
    led.
            at org.codehaus.mojo.exec.ExecMojo.execute(ExecMojo.java:363)
            at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPlugi
    nManager.java:490)
            at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
    ultLifecycleExecutor.java:694)
            ... 17 more
    Caused by: java.io.IOException: Cannot run program "C:\WINDOWS\Microsoft.NET\Fra
    mework\v4.0.30319\msbuild" (in directory "c:\workspace\something\client"): Create
    Process error=5, Access is denied
            at java.lang.ProcessBuilder.start(ProcessBuilder.java:460)
            at java.lang.Runtime.exec(Runtime.java:593)
            at org.apache.commons.exec.launcher.Java13CommandLauncher.exec(Java13Com
    mandLauncher.java:58)
            at org.apache.commons.exec.DefaultExecutor.launch(DefaultExecutor.java:2
    54)
            at org.apache.commons.exec.DefaultExecutor.executeInternal(DefaultExecut
    or.java:319)
            at org.apache.commons.exec.DefaultExecutor.execute(DefaultExecutor.java:
    160)
            at org.codehaus.mojo.exec.ExecMojo.executeCommandLine(ExecMojo.java:602)

            at org.codehaus.mojo.exec.ExecMojo.execute(ExecMojo.java:348)
            ... 19 more
    Caused by: java.io.IOException: CreateProcess error=5, Access is denied
            at java.lang.ProcessImpl.create(Native Method)
            at java.lang.ProcessImpl.<init>(ProcessImpl.java:81)
            at java.lang.ProcessImpl.start(ProcessImpl.java:30)
            at java.lang.ProcessBuilder.start(ProcessBuilder.java:453)
            ... 26 more
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: < 1 second
    [INFO] Finished at: Tue Mar 27 10:33:58 CDT 2012
    [INFO] Final Memory: 7M/494M
    [INFO] ------------------------------------------------------------------------

Anyone have success running msbuild using maven/java or running any windows process/batch file using maven?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T02:58:32+00:00Added an answer on June 2, 2026 at 2:58 am

    Moved to Windows 7 and it works. Dont know why it didn’t work on XP but it solves the problem for me.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
I am trying to understand how to use SyndicationItem to display feed which is
Basically, what I'm trying to create is a page of div tags, each has
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
this is what i have right now Drawing an RSS feed into the php,
I am trying to render a haml file in a javascript response like so:
I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
We're building an app, our first using Rails 3, and we're having to build
I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.