diff --git a/mosgi/jmx.remotelogger/pom.xml b/mosgi/jmx.remotelogger/pom.xml
index 1fba7aa..b52b9aa 100644
--- a/mosgi/jmx.remotelogger/pom.xml
+++ b/mosgi/jmx.remotelogger/pom.xml
@@ -34,6 +34,12 @@
   <dependencies>
     <dependency>
       <groupId>${pom.groupId}</groupId>
+      <artifactId>org.apache.felix.framework</artifactId>
+      <version>1.0.0</version>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>${pom.groupId}</groupId>
       <artifactId>org.osgi.core</artifactId>
       <version>1.1.0-SNAPSHOT</version>
       <scope>provided</scope>
@@ -50,7 +56,12 @@
        <version>3.0.1</version>
        <scope>provided</scope>
     </dependency>
-   
+    <dependency>
+       <groupId>${pom.groupId}</groupId>
+       <artifactId>org.apache.felix.mosgi.jmx.agent</artifactId>
+       <scope>provided</scope>
+       <version>0.9.0-SNAPSHOT</version>
+     </dependency>
   </dependencies>
 
   <build>
diff --git a/mosgi/jmx.remotelogger/src/main/java/org/apache/felix/mosgi/jmx/remotelogger/Logger.java b/mosgi/jmx.remotelogger/src/main/java/org/apache/felix/mosgi/jmx/remotelogger/Logger.java
index ef44cfc..416f163 100644
--- a/mosgi/jmx.remotelogger/src/main/java/org/apache/felix/mosgi/jmx/remotelogger/Logger.java
+++ b/mosgi/jmx.remotelogger/src/main/java/org/apache/felix/mosgi/jmx/remotelogger/Logger.java
@@ -20,6 +20,7 @@
 import org.osgi.framework.BundleActivator;
 import org.osgi.framework.BundleContext;
 import org.osgi.framework.ServiceReference;
+import org.osgi.framework.ServiceRegistration;
 import org.osgi.framework.BundleException;
 import org.osgi.framework.ServiceListener;
 import org.osgi.framework.ServiceEvent;
@@ -44,6 +45,7 @@
 public class Logger extends NotificationBroadcasterSupport implements LogListener,BundleActivator,ServiceListener, LoggerMBean, Serializable{
 
   private static final String REMOTE_LOGGER_ON_STRING="OSGI:name=Remote Logger";
+  private ServiceRegistration mbean_sr=null;
 
   private String version=null;
   
@@ -96,14 +98,14 @@
         if (as[0].equals(LogReaderService.class.getName())){
           this.registerLogReaderService(servicereference);
         }else if (as[0].equals(MBeanServer.class.getName())){
-          this.registerToAgent(servicereference);
+          //this.registerToAgent(servicereference);
         }
 	break;
       case ServiceEvent.UNREGISTERING :
         if (as[0].equals(LogReaderService.class.getName())){
 	  this.unRegisterLogReaderService(servicereference);
         }else if (as[0].equals(MBeanServer.class.getName())){
-          this.unRegisterFromAgent();
+          //this.unRegisterFromAgent();
         }
 	break;
     }
@@ -151,11 +153,11 @@
     this.version=(String)bc.getBundle().getHeaders().get(Constants.BUNDLE_VERSION);
     this.bc=bc;
     this.log(LogService.LOG_INFO, "Remote Logger starting "+version);
-    try{
-      this.remoteLoggerON=new ObjectName(Logger.REMOTE_LOGGER_ON_STRING);
-    }catch(MalformedObjectNameException e){
-      throw new BundleException("Logger.Logger:objectName invalid", e);
-    }
+
+    java.util.Properties p = new java.util.Properties();
+    p.put(org.apache.felix.mosgi.jmx.agent.Constants.OBJECTNAME, REMOTE_LOGGER_ON_STRING);
+    this.mbean_sr = this.bc.registerService(LoggerMBean.class.getName(), this, p);
+
     try{
       bc.addServiceListener(this,"(|(objectClass="+LogReaderService.class.getName()+")"+
                                    "(objectClass="+MBeanServer.class.getName()+"))");
@@ -167,10 +169,6 @@
       this.registerLogReaderService(sr);
     }
 
-    ServiceReference sr2=bc.getServiceReference(MBeanServer.class.getName());
-    if (sr2!=null){
-      this.registerToAgent(sr2);
-    }
     this.log(LogService.LOG_INFO, "Remote Logger started (logLvl="+logLvl+")"+version);
   }
      
@@ -183,11 +181,13 @@
       this.bc.removeServiceListener(this);
     }
     if (this.agent!=null){
-      this.unRegisterFromAgent();
+      //this.unRegisterFromAgent();
     }
     this.agent=null;
     this.lrs=null; 
     this.log(LogService.LOG_INFO, "Remote Logger stopped"+version);
+    this.mbean_sr.unregister();
+    this.mbean_sr=null;
     this.bc=null;
   }
 
@@ -207,23 +207,6 @@
     }
   }
 
-  private void registerToAgent(ServiceReference sr){
-    this.agent=(MBeanServer)bc.getService(sr);
-    try{   
-      this.agent.registerMBean(this, this.remoteLoggerON); 
-    }catch(Exception e){
-      e.printStackTrace();
-    }
-  }
-
-  private void unRegisterFromAgent(){
-    try{
-      this.agent.unregisterMBean(this.remoteLoggerON);
-    }catch(Exception e){
-      //e.printStackTrace();
-    }
-  }
-
   private void log (int level, String message){
     ServiceReference lsn=bc.getServiceReference(LogService.class.getName());
     if (lsn!=null){
