Quantcast
Channel: Exchange Server Development forum
Viewing all 7132 articles
Browse latest View live

Dysfunctional Exchange 2007; Repair or Disaster Recovery

$
0
0

I have a dysfunctional (to put it mildly) Exchange Server that is hosted by a WS03r2x64/DC.  This DC hosts all roles of Exchange 2007.  To address some previous hardware issues, we re-imaged this DC/machine onto a new/bigger disc subsystem and did a Repair/Install to facilitate (F6) the needed/new disc drivers.  Afterwards, the said Exchange/IIS problems surfaced.

Currently, there are no AD or network/DNS issues as reported by comprehensive dcDiag/NetDiag testing nor are there any DNS, DS, or FRS error events in those logs.  However, iisAdmin won't run (invalid machinekey) and neither will Exchange Powershell (as is needed to work on the IIS issue).

My first goal is to get this DC upgraded to WS08r2 and to still host Exchange on such.  Budgetarty reasons prevent us from going to WS12 at this time or from properly hosting Exchange.  (We suspect by fall of this year to properly migrate/commission these instances, however, we won't be able to do such before WS'03 becomes unsupported in the next few months.)

So my question is which path do i follow:
  1) Do i pursue a remedy for PowerShell so i can use it to preserve IIS settings for Outlook/web and then rebuild IIS (and get this `03DC and Exchange completely functional before doing the WS08r2 migration)?

  2) Do i just preserve the Exchange db and then install WS08r2 and do a disaster recovery of Exchange (from the preserved db)?  -Is this even feasible?

All comments/suggestiongs are immensely appreciated!

Thanks,
GlennXS


Glenn of xSyLent


EWS Java API can't get email that hasAttachment

$
0
0

I have some issue in getting some attachment using ews java API 1.3 SNAPSHOT, i want to get Attachment in my email, here my code :

try {
    ExchangeService service;
    service.setUrl(new URI("https://" + myserver + "/ews/Exchange.asmx"));
    ExchangeCredentials credentials = new WebCredentials(username, password);
    service.setCredentials(credentials);
    ItemView view = new ItemView(Integer.MAX_VALUE);
    view.getOrderBy().add(ItemSchema.DateTimeReceived, SortDirection.Ascending);
    Folder folder = Folder.bind(service, WellKnownFolderName.Inbox);
    FindItemsResults<Item> results = service.findItems(folder.getId(),view);
    service.loadPropertiesForItems(results, new PropertySet(BasePropertySet.FirstClassProperties, EmailMessageSchema.Attachments));

        for (Item item : results) {
        Item itm = Item.bind(service, item.getId(), new PropertySet(BasePropertySet.FirstClassProperties, EmailMessageSchema.Attachments));
        EmailMessage emailMessage = EmailMessage.bind(service, itm.getId(), new PropertySet(BasePropertySet.FirstClassProperties, EmailMessageSchema.Attachments));
        if (emailMessage.getHasAttachments()) {
                for (Attachment attachment : emailMessage.getAttachments()) {
                    String FileExtension = getFileExtension(attachment.getName());
                    File TempFile = File.createTempFile(attachment.getName(), FileExtension);
                    attachment.load(TempFile.getAbsolutePath());
                }
            }
        }
} catch (Exception e) {
    logger.error("Error ", e.getMessage());
}

My issue is it can get another email that has no attachment and always skip email that has an attachment, the example is like this, In my inbox i have this email list

  • from: a@gmail.com (has attachment)
  • from: b@mycompany.com (no attachment)
  • from: c@hiscompany.com (has attachment)
  • from: d@mycompany.com (no attachment)

And when i run my code, it always get email that has no attachment, like this:

  • from: b@mycompany.com (no attachment)
  • from: d@mycompany.com (no attachment)

and skip the other email that has attachment, i have no idea how can this happen. Can someone help me please?

EDB to PST Converter

$
0
0
Which of the two is the better option? Stellar Phoenix exchange db recovery or Kernel exchange server recovery tool or probably another tool?

I have a couple of EDB files that I need to extract mailboxes from but I don't have an exchange server to fire them up with.

EWS error gettingEvents

$
0
0

Im having an issue with Office 365 EWS (its only Office 365, Exchange 2010 and 2013 work fine).  I can create my pull subscription without error but when I go to use it by calling

getEvents()


I receivean error:

ErrorNoRespondingCASInDestinationSite

The following error occured while retrieving events for exchange resource: <room address> - Exchange Web Services are not currently available for this request because none of the Client Access Servers in the destination site could process the request.

Here is some code snippets

Using autodiscover and setting up credentials

this.exchangeService.Credentials = new NetworkCredential(this.Username, this.Password);
                    try {
                        this.exchangeService.AutodiscoverUrl(this.Username, RedirectionCallback);
                    }
                    catch(Exception ex)
                    {
                        Logger.WriteToEventLog(EventLogEntryType.Warning, 104, "ExchangeDataAccess, AutodiscoverURL error: " + ex.Message);
                    }

                    if (exchangeService.Url == null)
                    {
                        this.ExchangeServerURL = GetOffice365EWSUrl(this.Username);
                        this.exchangeService.Url = new Uri(this.ExchangeServerURL);
                        this.exchangeService.CookieContainer = new CookieContainer();
                    }


Afterwhich we Login and find our exchange user that we will perform all operations under

ServicePointManager.ServerCertificateValidationCallback = (sender1, certificate, chain, errors) => true;

                string username = this.Username;
                if (this.authenticateContext.GetExchangeServerVersion().Contains("365"))
                {
                    username = this.Username.Remove(this.Username.IndexOf("@"));
                }

                NameResolutionCollection resolveNameResult = this.exchangeService.ResolveName(username, ResolveNameSearchLocation.ContactsThenDirectory, true);

                if (resolveNameResult.Count() > 0)
                {
                    roomEmailAddress = resolveNameResult[0].Mailbox.Address;
                    if (!string.IsNullOrEmpty(roomEmailAddress))
                    {
                        this.ExchangeUserEmailAddress = roomEmailAddress;
                        logMsg.AppendLine("Logged into Exchange with " + roomEmailAddress + " successfully, RetrieveRoomsList is next");
                    }
                }


We then get a SubscribeResponse and save it to a list

                    subscribeResponse = this.exchangeDataAccess.ExchangeSubscribe(syncPoint.ThirdPartyId, syncPoint.Watermark, true);


We pass the above object into a wrapper method to get all Events from the EWS

            Dictionary<PullSubscription, IEnumerable<ItemEvent>> mailboxEvents = null;

            GetEventsResults eventsResults = subscription.GetEvents();

            if (eventsResults == null || eventsResults.ItemEvents.Count() == 0) {
                return mailboxEvents;
            }

            mailboxEvents = new Dictionary<PullSubscription, IEnumerable<ItemEvent>>();
            mailboxEvents.Add(subscription, eventsResults.ItemEvents);
            return mailboxEvents;

The line that calls subscription.GetEvents() is where the exception indicated at the top is returned.  

There is another layer of complexity added on because our Exchange user has a domain name of @FOOlab.onmicrosoft.com where as all of the rooms being managed have a domain name of @LAB.FOO.COM

According to the customer this is ADFS authentication, however I really don't know much about it.

I can say however that this code base did work (got events) and then something seemed to change and the error started popping up.  Originally I thought the customer changed something but we have tested this against another Office 365 (without ADFS) and saw the same error, so now I don't know what to think.   


Failing to authenticate Calendar permission in consent screen

$
0
0

I have written an application that uses office365 REST api's to sync calendars, emails and contacts. For OAuth during the testing phase I had created a common application in Azure AD with permissions enabled for Calendar, Mails and Contacts. Now to push this application for production I want to create two different applications in Azure one for Contacts and mails and other for Calendar.

I successfully created the applications but when I try to authenticate Calendar sync, it shows me consent screen with permissions only for calendar and when I click "Accept" in consent screen I get this as response,

Array
(
[error] => temporarily_unavailable
[error_description] => AADSTS90090: A transient error has occurred.
                       Please try again.
                       Trace ID: 9bf71aee-6acc-4443-b999-8eaf58ef0f3d
                       Correlation ID: 720d3469-de71-4f03-9703-
                                       5f5cc6374232
                       Timestamp: 2015-02-18 09:50:11Z
)

The other application created only for Contacts and Mails works fine.


Outlook automation failing to send e-mails via Exchange.

$
0
0

I'm not sure if this is the correct place to post this but here goes:

We  have an application written in VB6 which automatically generates e-mails in Outlook . The customer in question was using use Outlook 2010 with Exchange 2003 they have recently migrated to Exchange 2013. Since migrating all generated e-mails have stopped being sent out and are all being bounced back with:

Remote Server returned '550 5.1.0 RESOLVER.ADR.InvalidInSmtp; encapsulated INVALID address inside an SMTP address (IMCEAINVALID-)' 

When I go into Outlook to try to resolve the issue and drive down into the properties of the recipient of the e-mail the e-mail type field is blank (see screen shot below) where as before the migration the e-mail type always defaulted to SMTP. I'm not sure if this is what is causing the issue but its the only difference i can see post migration.

I have looked at the Outlook object model and cannot see where I can set the E-Mail Type property. Can anybody advise my how i can programatically set the E-Mail Type property to SMTP

Thanks in advance

Chris


ASP.NET - MVC pattern

$
0
0
Hi,

I am trying to implement MVC pattern with ASP.NET in the following way without using the MVC framework. 

    - page1.aspx page (html - View)
    - page1.cb (code behind - Controller)
    - Module1UIHelper.cs (Service class for a module - Model 


please let me know if this approach is ok and other ways to implement MVC pattern with ASP.NET.

Thanks,
Raghav

The account does not have permission to impersonate the requested user

$
0
0

I get a runtime error trying to impresonate a user - code below

  Service = New ExchangeService()

        Service.Url = New Uri(ApplicationItems.ExchangeURL)
        Service.Credentials = New NetworkCredential(username, password)
        Service.ImpersonatedUserId = New ImpersonatedUserId(ConnectingIdType.SmtpAddress, emailAddress)


Problem getting calendar event with recurring using EWS Java client API 1.2

$
0
0
I am using EWS 1.2 Java client API for getting calendar events. I am able to get Recurring information of the event which is created through API's 

appointment.save(), but not able to get recurring information of the event created in OWA interface, I get following error during the bind:

===================================

Exception: Connection not established

microsoft.exchange.webservices.data.EWSHttpException: Connection not established

at microsoft.exchange.webservices.data.HttpClientWebRequest.throwIfConnIsNull(HttpClientWebRequest.java:394)

at microsoft.exchange.webservices.data.HttpClientWebRequest.getResponseHeaders(HttpClientWebRequest.java:280)

at microsoft.exchange.webservices.data.ExchangeServiceBase.processHttpResponseHeaders(ExchangeServiceBase.java:1045)

at microsoft.exchange.webservices.data.SimpleServiceRequestBase.internalExecute(SimpleServiceRequestBase.java:58)

at microsoft.exchange.webservices.data.MultiResponseServiceRequest.execute(MultiResponseServiceRequest.java:144)

at microsoft.exchange.webservices.data.ExchangeService.internalBindToItems(ExchangeService.java:1364)

at microsoft.exchange.webservices.data.ExchangeService.bindToItem(ExchangeService.java:1407)

at microsoft.exchange.webservices.data.ExchangeService.bindToItem(ExchangeService.java:1430)

at microsoft.exchange.webservices.data.Appointment.bind(Appointment.java:70)

at microsoft.exchange.webservices.data.Appointment.bindToRecurringMaster(Appointment.java:176)

at microsoft.exchange.webservices.data.Appointment.bindToRecurringMaster(Appointment.java:152)

============================

This happens if I use: Appointment.bindToRecurringMaster or Item.bind(service, id, appointmentProps) or findAppointments(). 

Works fine for events which doesn't have recurring. Only issue with events containing recurrence created through OWA. These are the propertySet:

new PropertySet(BasePropertySet.IdOnly,

                                ItemSchema.Subject,

                                AppointmentSchema.AppointmentType,

                                AppointmentSchema.DeletedOccurrences,

                                AppointmentSchema.FirstOccurrence,

                                AppointmentSchema.LastOccurrence,

                                AppointmentSchema.IsRecurring,

                                AppointmentSchema.Location,

                                AppointmentSchema.ModifiedOccurrences,

                                AppointmentSchema.OriginalStart,

                                AppointmentSchema.Recurrence,

                                AppointmentSchema.Start,

                                AppointmentSchema.End);

If I remove Recurrence it gives the response. 

Thanks.

Monitor mailbox and send data to a SharePoint list.

$
0
0

Hi!

I asked this question in the SharePoint forum and was told there was no easy way to achieve this in SharePoint. Basically it's about monitoring a mailbox and based on its header either create a new list item or update an existing. Like this:

http://www.c-sharpcorner.com/UploadFile/sagarp/create-update-delete-a-list-using-client-object-model-cso/<o:p></o:p>

It's going to create or update helpdesk issues in SharePoint through e-mails and their replies.

Anyone that has a sharp solution for this?

Kind regards

// Brown

Client does not have permission to send as this sender

$
0
0

We have a CRM web application hosted on a server. When a user launches the site, the site provides facility to the customer to send the query into the system using the email. The website provides the filed for the customer to enter customer’s email ID. The customer email address is used by the system to send the response back.

 

We are doing a new implementation for SMTP authentication for the emails send into the contact center using a public website. The flow of the system to use the SMTP authentication is:

  1. Customer launches the website.
  2. Customer chooses to send the his/her query using the email from the website.
  3. Website asks for the customer’s address, so that the query can be answered back to the provided email address say customer@gmail.com .
  4. We have an account configured on the MS-Exchange 2010 say support@system.com
  5. So before sending the email the website system performs the SMTP Authentication using the credentials of support@system.com  
  6. Now the system creates the email MIME using the email address provided by the customer on the website i.e. say customer@gmail.com.
  7. After successful SMTP authentication for the address   support@system.com system starts sending the email.
  8. Here we are facing the issue:

While sending the email if the customer’s address is also configured on the same exchange used by the system i.e. exchange on support@system.com is configured  then website system is able to relay or send the email.

If the customer’s address is not configured on the same exchange used by the system where support@system.com is configured then the system is not able to send the email it results into the error of: “Client does not have permission to send as this sender customer@gmail.com.

 

In short if the website performs the  SMTP authentication then it requires the FROM address configured on the same exchange used for the smtp authentication in the email MIME from address.

 

Configuration tries:

  1. As suggested on various forums and at Microsoft tech group we tried following things but no success:
    1. Checked the checkbox “Authenticated Users”  selected “Accept any Sender”.
    2. Created a new relay and given the IP of the machine hosting the website or trying to send the email
    3. Run the command from the EMC “Exchange management console”

Add-AdPermission -Identity "Default Receive Connector" -User "NT AUTHORITY\Authenticated Users" -ExtendedRights ms-Exch-SMTP-Accept-Any-Sender.

 

 

Outlook Anywhere Exchange 2003

$
0
0

Does anyone have the rpcnofrontend.zip file or the executable so that I can setup Outlook Anywhere on Exchange 2003 without having to dive into the registry myself? Apparently this tool has worked wonders but it appears as though it has since been taken down. I need to activate Outlook Anywhere successfully so that the migration of mailboxes from Exchange 2003 to Outlook 365 can move successfully. (apparently, Outlook Anywhere has to be fully functional for this to happen).

Exchange 2003 Cluster failed

$
0
0

Hello everyone

I have a Windows 2003 failover cluster for MS exchange 2003. After some updates, I lost access to all physical disk resources, including Quorum partition. I folowed the official MS procedure to restore the resources, but it failed.

  The hard-disks are FC HDDs from EMC VNX 5500 storage. In disk management, I am able to see the disks, but in Windows Explorer i don't have access to the disks (F:\ is not accessible). If I try to remove HDD resources from cluster i get an error (probabily because Cluster service is down).

 Does anyoane know how to manualy unlock resouces from MS Cluster ??? Or how can I get access to the mailbox databases to try to restore the data on another server?

Thank you


[E2010] [TA] [C#] [Windows]: Add my assembly to Transport Agent project

$
0
0

Hello, please help me determine how i should add additional assembly (MimeKit) for my Transport Agent project. As usual I added refference and rebuild project then copy to Exchange Server and try to install it, but have error:

Could not load file or assembly 'file:///C:\Program Files\Microsoft\Exchange Server\V14\TransportRoles\agents\SmtpAgents\BodyConversion\BodyConversion.dll' or one of its dependencies. This assembly is built by a runtime newer than the currently loaded runtime and cannot
 be loaded.
    + CategoryInfo          : InvalidArgument: (:) [Install-TransportAgent], BadImageFormatException

    + FullyQualifiedErrorId : 30AF3521,Microsoft.Exchange.Management.AgentTasks.InstallTransportAgent

Should I install them on Exchange Server? What folder is for those dll's?



Wrong Organizer Name

$
0
0

Hai,

    I am developing a sample calendar application. Everything is working fine but sometimes organizer is mismatched. I am developing this by using ews manged api with version 2007_sp1.  

I am getting this problem after my mailbox is updated to exchanged 2013.

Any help is appreciated.

Thank you.


#554 5.3.4 STOREDRV.Submit; Content conversion limit(s) exceeded ## "This message exceeds the maximum message size allowed".

$
0
0

Hey Guys,

I have an issue with one of my company user. Whenever he is sending any mail with attachement of 2MB or more he is getting the undelevery message as mentioned above in subject line.

I have checked everything possibly that can cause the delevry failure. E.g.

[PS] H:\>Get-SendConnector|fl *size

MaxMessageSize : unlimited

MaxMessageSize : unlimited

[PS] H:\>Get-ReceiveConnector|fl *size

MaxHeaderSize  : 64KB
MaxMessageSize : 40000KB

MaxHeaderSize  : 64KB
MaxMessageSize : 40000KB

MaxHeaderSize  : 64KB
MaxMessageSize : 150MB

MaxHeaderSize  : 64KB
MaxMessageSize : 40000KB

MaxHeaderSize  : 64KB
MaxMessageSize : 40000KB

[PS] H:\>Get-TransportConfig | fl MaxSendSize

MaxSendSize : 40MB

[PS] H:\>Get-TransportConfig | fl MaxSendSize

MaxSendSize : 40MB

Please help me to resolve this issue...

Thanks,


Amit Kumar Sharma

List of supported Microsoft.Exchange.WebServices.dll versions

$
0
0

I am looking for a definitive list of Microsoft.Exchange.WebServices.dll versionsthat are supported and those, if any, that are EOL. Anyone know for sure?

Regards

[E2013][EWS][JS][Windows] JavaScript API Getting Session.Accounts

$
0
0
Can you get the accounts available in the current session through the javascript api for office mail apps? Would that information be available through an EwsRequestAsync call? 

Always asking external domain user name and password

$
0
0

Hi,

i am having problem with SBS 2008, the main problem is when we open outlook always asking external domain user name and password and its keep poping up also. if i try to put local AD user name and password after some time again same problem.

another problem is cannot start default web site . when i start showing getting error another website using same port)

hope i will get the help from here


Thomas

Failing to authenticate Calendar permission in consent screen

$
0
0

I have written an application that uses office365 REST api's to sync calendars, emails and contacts. For OAuth during the testing phase I had created a common application in Azure AD with permissions enabled for Calendar, Mails and Contacts. Now to push this application for production I want to create two different applications in Azure one for Contacts and mails and other for Calendar.

I successfully created the applications but when I try to authenticate Calendar sync, it shows me consent screen with permissions only for calendar and when I click "Accept" in consent screen I get this as response,

Array
(
[error] => temporarily_unavailable
[error_description] => AADSTS90090: A transient error has occurred.
                       Please try again.
                       Trace ID: 9bf71aee-6acc-4443-b999-8eaf58ef0f3d
                       Correlation ID: 720d3469-de71-4f03-9703-
                                       5f5cc6374232
                       Timestamp: 2015-02-18 09:50:11Z
)

The other application created only for Contacts and Mails works fine.


Viewing all 7132 articles
Browse latest View live