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

Missing MailboxType in Exchange 2010

$
0
0

I'm using the ews-java-api to connect to an Exchange 2010 server, retrieve Appointments from it, parse over the attendee list of each appointment and if one of them is a distribution group I'm expanding it and replacing the group with the email list in my application.

I'm using the MailboxType property of the attendee in order to figure out which attendee is a distribution group by checking for the "PrivateDL" MailboxType. This works when my application is connecting to an Exchange 2013 or an Exchange 2016 server. When connecting to Exchange 2010 the MailboxType is always null. Below is a small piece of code I'm using to check for the mailbox type:

FolderId roomFolderId = new FolderId(WellKnownFolderName.Calendar, new Mailbox(roomEmail));
FindItemsResults<Appointment> appointments = exchangeService.findAppointments(roomFolderId, calendarView);

for (Appointment appointment : appointments) {
  appointment.load();

  log.info("Parsed appointment: " + appointment.getId());
  for (Attendee attendee : appointment.getRequiredAttendees()) {
    log.info("  - attendee: " + attendee.getAddress());
    log.info("    - mailbox type: " + attendee.getMailboxType());
  }

For a meeting with one attendee I get the following:

1374 [main] INFO EWSTest  - Parsed appointment: AAMkADQ1ZGIxZmM0LTM5MTEtNDhhYy04YWRmLTA2NTJiYzg2MjMzZABGAAAAAABVE7hxWhJkQ7Hq4/MBQ0WKBwBQSEDfqYqrSriR4eFxQpV2AAAAAAENAABQSEDfqYqrSriR4eFxQpV2AACbd+qIAAA=
1374 [main] INFO EWSTest  -   - attendee: attendee@mail.com
1374 [main] INFO EWSTest  -     - mailbox type: null

I've also checked the server response and the server won't return the MailboxType of an attendee but it will return the MailboxType of the organizer:

<t:Organizer><t:Mailbox><t:Name>Organizer Name</t:Name><t:EmailAddress>organizer@mail.com</t:EmailAddress><t:RoutingType>SMTP</t:RoutingType><t:MailboxType>Mailbox</t:MailboxType></t:Mailbox></t:Organizer><t:RequiredAttendees><t:Attendee><t:Mailbox><t:Name>Attendee name</t:Name><t:EmailAddress>attendee@mail.com</t:EmailAddress><t:RoutingType>SMTP</t:RoutingType></t:Mailbox><t:ResponseType>Unknown</t:ResponseType></t:Attendee></t:RequiredAttendees>
Do I need to provide additional properties in the PropertySet used by the appointment.load() method or does something else need to be configured server side or is this an issues specific to Exchange Server 2010?


update Active sync URLs on my all CAS servers

Cannot Install Exchange 2007 SP3 - Failing

$
0
0

I need to install Exchange SP3 in order to install the lastest rollup package as well since we are going to migrate to exchage 2013.

getting this error when Installing Exchange SP3

"Hub Transport Role Failed Error: Process execution failed with exit code -1"

Need help installing SP3 the the latest rollup.

Thanks

Owa error Exchange 2013 CU13 SDServerErr; System.Xml.XmlException

$
0
0
Good afternoon!There is a problemwith the entrancethroughowa,whileerrors inzhuralahnot fixed.There is aconfiguration1CAS + 2MB. Configuration changesare notmade,andCASrestoringa week agohas not broughtresults.

:-(
something went wrong
An unexpected error occurred and your request could not be handled.

X-ClientId: WZZZ - S0Q0 - AROT - RYQRG
X-OWA-Error: SDServerErr; System.Xml.XmlException
X-OWA-Version: 15.0.1210.3
X-FEServer: EX01
X-BEServer: ex04.corp.com
Date: 23.07.2016 22:06:16

I tried tore-create thevirtualdirectory, andchange thebindingsbutthat does nothelp.

Removing Exchange Server 2016

$
0
0

Hello

Our business has 6 Exchange 2010 SP3 Ru11 servers.  Two client access and 4 DAG members.  Our head of IT wanted to install an Exchange 2016 server to give the users a feel of what Office 365 was like before migrating them over.  Since the head of IT has left before the migration, he never set up 2016 correctly and now the users are on office 365 we have no need for the Exchange 2016 server.

We still have on prem as we still have 40% of the user base to be migrated but I would like to remove 2016 as its not used.

I have uninstalled legacy exchange servers before but never newer versions.  I was wondering if this is the same process and not affect our current 2010 servers and the 2016 uninstall will remove the entries from AD with no issue?

Regards

John

Is it possible to use custom extended property to set our own unique id for every meeting??

$
0
0

I am using EWS managed api latest version. I use streaming notification to get Id's of meetings whenever created, modified or moved(which i use to identify deleted meetings)

The problem was ItemIDs are not constant, when they are deleted they generate new itemId. So when ever i recieve an ItemId(while new meeting is created) from exchange i want to set custom extended ID to that particular event.

My question was when they were deleted they are moved to delete folder, so is there possiblility to access them through extended property.

for eg: i will look into deleted folder and try to find out events which has customID's and then i will delete them from my database.

Is it a good way to solve this problem? Are there any better solution for this problem?

Thanks in advance

SubscribeToPushNotificationsOnAllFolders for a specific mailbox

$
0
0

Is it possible to somehow provide a mailbox for which the  push notification is supposed to be received other than the user's account (used to generate the service) by which the method SubscribeToPushNotificationsOnAllFolders method had been called?

I am actually trying to read all the folders inside the group-mailbox for which the user is a member.

I was able to do it using SubscribeToPushNotifications method by supplying the all the folders to it. But it might not cater the situation where any folder had been created after the subscription is made.


Powershell C#- Loop through a csv file and take action

$
0
0

I am not a programmer, just trying to grab code from here and there to enable or disable skypeB users in bulk to make the job a bit easier and faster.

wrote the code below, but lines 41-43 are not working in the script. They work individually if I run them from the ps> prompt.

Any help will be appreciated. Script is still not completed do do other things as well. Hopefully when completed, I can post the final script here :?) don't pay any attention to the commented lines, that is just information to keep me calm...

#sAMAccountName,mail,msRTCSIPLine,ConferencingPolicy,RegistrarPool,LineURI,sipaddress,action

$UserList = Import-CSV "$PSScriptRoot\Skypebuserlist.csv"

#$category = "user"
#$name = "uid"
#$data = "sharifm*"
#$attributes = @("givenName", "mail", "manager")
#$attributes = @("mail","givenName","sn","msRTCSIP-Line","uid")
#$attribute ="givenName"

##$Header =  $attributes -join','
#Write-Host $Header
#$lines = @()
#$lines += $Header

#$results = @()

foreach ($user in $UserList) {
    Write-Host ("The User {0} with Phone ({1}) and Action = {2}" -f $user.sAMAccountName, $user.mail, $user.RegistrarPool, $user.sipaddress, $user.ConferencingPolicy, $user.msRTCSIPLine, $user.action)

    $poolName = (Get-CsUser | Group-Object RegistrarPool | sort-object count | select-object -first 1).Name

    if ($user.action -eq "disable")
    {
        Write-Host "disable account"
        Write-Host Get-CsUser $user.sAMAccountName
        if (Get-CsUser $user.sAMAccountName){
            disable-CsUser $user.sAMAccountName
        }
        else
        {
            Write-Host "not found"
        }
    }
    else
    {
        Write-Host ("Enable account for POOL {0} " -f $poolName)
        if ($user.msRTCSIPLine) {
            Write-Host "has phone"
          Enable-CsUser -Identity "$user.sAMAccountName" -RegistrarPool "$poolName" -SipAddress "sip:$user.sipaddress"
          Set-CsUser $user.sAMAccountName -EnterpriseVoiceEnabled $True -Confirm:$True
          Set-csuser $user.sAMAccountName -LineURI $user.msRTCSIPLine
                
        }
        else{
            Write-Host "does not have phone"
        }

    }
    Write-Host "-----------------------------------------------------------------------------"
}
Write-Host
Write-Host "File Done"
Write-Host


How can we know which calendar meeting is deleted from EWS managed api

$
0
0

I am using lastest version of EWS managed api and i am using extended property to set GUID for every meeting.

What i was trying to achieve was to look into delete items and get all GUIDs so that i can search into my database to find the matching GUID so that i can remove it from database.

So where i should look to get the cancelled meeting? and how can i search for them?

Is there any other way to know which meeting is cancelled.

[EWS] [E2013] Email with table and image is altered

$
0
0
I have been testing our software, which exports messages from Office 365 via EWS.  I have a test case of a message that is just a simple html table with a border, with some text and an image in the table.  The message looks fine in Outlook, but when viewed with OWA, the table border is gone, and the image is empty.  I then run the software, which obtains the message in MIME format.  Looking at the results confirms that the "Border" property of the table is missing, and the jpeg MIME part is a small, empty image.  But the message continues to be fine in Outlook.  This sure looks like a bug in Exchange/EWS somewhere.  Is there any place I can report this?  I have a .msg file that will demonstrate the problem.

How to get itemid of an occurence if the meeting when it is cancelled from EWS api

$
0
0

Normally when ever a meeting is cancelled i use moved eventtype to get olditemId using that i delete the cancelled meeting id´s from databse.

But for recurring meetings when a single occurence is cancelled only modified event is triggered. So i cant get olditemId. So in this scenario how can i idetify cancelled occurence.

Please Suggest some best and simple ways to deal with this problem.

I have one more doubt like how we get to know whether an user was internal user or external user from EWS.

Thanks in advance,

Rahul


SSO Implementation after Cutover Migration (Exchange 2007)

$
0
0
We have completed the Cutover Migration and now we are planning to implement Single Sign-on using AD Connect. From my research, before installing AD Connect I still need to convert the Exchange 2007 mailboxes to mail-enabled users. I have found this article(https://support.office.com/en-us/article/Convert-Exchange-2007-mailboxes-to-mail-enabled-users-a1f79f3c-4967-4a15-8b3a-f4933aac0c34), but my question is, will it be the procedures that I will follow as this article refers to Staged Migration? If not, can someone provide a step-by-step procedure and powershell script to convert our mailboxes to MEU. Advance thank you...

EWS Push notification subscription service (for exchange online) become unstable when the office 365 data center doing migration

$
0
0

Our customer have some mailboxes located in the office 365 (exchange online).

And we use EWS push notification subscription service to receive New mail event notification of our customer's mailboxes.

Generally, the EWS push notification subscription service works well, but recently we found the push notification service become unstable (the subscription become invalid, and re-subscribe also not work), which seems to be caused by office 365 data center migration (we confirmed with our customer that they receive MS's notification about the data center migration).

So, my question is whether this issue (EWS push notification unstable) is really caused by the data center migration?

And if this kind of issue happened, should we just waiting the migration complete and then do re-subscribe?

Some update:

When the above issue happens, the EWS push notification subscription service will post some message which contains--

Invalid data source operation., Current AD session re-homed to organization APCPR04A004.PROD.OUTLOOK.COM/Microsoft Exchange Hosted Organizations

to our web service.

Thanks in advance~

Send email without leaving a copy in the Sent folder outlook c#

$
0
0
When i am sending mail through outlook in c# ,all the mails are saved in sent box. Is there any way which does not leave the copy of mail in sent folder programatically.

Returning unique User ID from Get-MailboxFolderPermission cmdlet

$
0
0

I'm currently trying to prepare some automation using Exchange PowerShell commandlets. I've faced some problem.

When running Get-MailboxFolderPermission cmdlet on Exchange server it's returning results, but'User' field in resultset looks like DisplayName of the user. It's not unique and I need solution that returns unique user identifier (likeSamAccountName or UserPrincipalName).

Following this post - http://serverfault.com/questions/503014/how-to-get-mailbox-folder-permissions-with-samaccountname-or-upn - I was able to useUser.ADRecipient.UserPrincipalName property, but it looks that it is available only on Exchange 2013 instance, and can't be used on earlier Exchange versions.

I've also found some PowerShell function (http://pastebin.com/MQPLJ5pC) which is resolvingDisplayName into unique user identifier.

It looks like it's possible to tie it all together, but I'm wondering if there is some simpler way achieving it.

I'm interested in solution that works on Exchange 2007, 2010 and 2013.

Any help is really appreciated.


Get mailbox folder permissions for “remote” mailboxes

$
0
0

I'm using PowerShell commandlets to extract MailboxFolderPermissions. I'm usingGet-MailboxfolderStatistics to get list of folders for particular mailbox and thenGet-MailboxfolderPermission to get permissions for all available folders.

All is working fine for mailboxes hosted locally on Exchange server I'm connected to(using remote ps session). But in the same domain there is another Exchange server and mailboxes hosted on it are also listed when invoking Get-Mailbox on the first one.

When I try to run Get-MailboxfolderStatistics or Get-MailboxfolderPermission for such "remote" mailbox I'm getting en error:

For Get-MailboxFolderStatistics cmdlet:

Unable to retrieve mailbox folder statistics for mailbox xxxxxxx@xxxxxx.local. Failure: Error code -2146233088 occurred with message Cannot open mailbox /o=xxxxxxxx/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Configuration/cn=Servers/cn=EXCH2013/cn=Microsoft System Attendant.. + CategoryInfo: ReadError: (:) [Get-MailboxFolderStatistics],MailboxFolderStatisticsException + FullyQualifiedErrorId : BE037E6,Microsoft.Exchange.Management.Tasks.GetMailboxFolderStatistics + PSComputerName: xxxxxxxxxxx

For Get-MailboxFolderPermission cmdlet:

Cannot open mailbox /o=xxxxxxxx/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Configuration/cn=Servers/cn=EXCH2013/cn=Microsoft System Attendant. + CategoryInfo: NotSpecified: (0:Int32) [Get-MailboxFolderPermission], ConnectionFailedTransientException+ FullyQualifiedErrorId : A44BD817,Microsoft.Exchange.Management.StoreTasks.GetMailboxFolderPermission + PSComputerName: xxxxxxxxxxx

Does anyone know what could the cause of above errors?

Is it possible to list permissions for remote mailbox folders?

Because of security policy I can't connect to the second Exchange server directly. I can only access it's mailboxes only through first Exchange server.

I was also trying EWS, but it behaves similar - it returns proper results for "local" mailboxes, and throws an error when trying to extract permissions for "remote" mailboxes.

Any help is really appreciated.

Get calendar events from Outlook.com using Java API

$
0
0

I want to get all calendar events from Outlook.com using Java API. I tested this code to connect:

 public void findChildFolders(String username, String password) throws Exception
    {
        ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2010_SP2);
        ExchangeCredentials credentials = new WebCredentials(username, password);

//        URI jira_url = URI.create("outlook.live.com");
        service.autodiscoverUrl(username, new RedirectionUrlCallback());
        service.setCredentials(credentials);

        FindFoldersResults findResults = service.findFolders(WellKnownFolderName.Inbox, new FolderView(Integer.MAX_VALUE));

        for (Folder folder : findResults.getFolders())
        {
            System.out.println("Count======" + folder.getChildFolderCount());
            System.out.println("Name=======" + folder.getDisplayName());
        }
    }

    static class RedirectionUrlCallback implements IAutodiscoverRedirectionUrl
    {
        @Override
        public boolean autodiscoverRedirectionUrlValidationCallback(
            String redirectionUrl)
        {
            return redirectionUrl.toLowerCase().startsWith("https://");
        }
    }

But I get error stack:

microsoft.exchange.webservices.data.autodiscover.exception.AutodiscoverLocalException:TheAutodiscover service couldn't be located. at microsoft.exchange.webservices.data.autodiscover.AutodiscoverService.internalGetLegacyUserSettings(AutodiscoverService.java:742)

What is the proper way to implement this code?

Exchange 2010 (Hosting mode) to Office 365

$
0
0

Hello

I have a Exchange 2010 as Hosting mode where i have about 4 organization - i want to migrate that to office 365 but it failes with checking group membership - i have try with domain admin, organization admin and many many other things.

I have added administrator and organization administrator almost on all exchange groups but i still get a error.

Has anybody tryit this ? i use codetwo to migrate and all single exchange server has been succesfull with this tool.

I missin somthing but i cant figure it out.


Removing Exchange 2010 from server

$
0
0

I have migrated a client to a cloud based Exchange solution, and have no need for Exchange on their old in house server. It is currently hosting other applications, so I can't simply shut it down and retire the server. I want to remove exchange. But during the Readiness Checks, I keep getting errors thrown at me, and since this is an Exchange 2010 server, the "Click here for help" links no longer work. I apparently have a few mailbox and the Public Folders still open, and every search I do on removing them wants to show me how to first migrate the mailboxes somewhere else. I just want to delete Exchange, and don't need to save or migrate or backup ANYTHING. I would love a box that says "Ignore errors and just delete", but that's not an option. Here's what the Readiness Check gives me:

Summary: 5 item(s). 4 succeeded, 1 failed.
Elapsed time: 00:00:26


Configuring Prerequisites
Completed

Elapsed Time: 00:00:00


Mailbox Role Prerequisites
Failed

Error:
Uninstall cannot continue. Database 'COMPANY Mailboxes': This mailbox database contains one or more mailboxes, mailbox plans, archive mailboxes, or arbitration mailboxes. To get a list of all mailboxes in this database, run the command Get-Mailbox -Database<Database ID>. To get a list of all mailbox plans in this database, run the command Get-MailboxPlan. To get a list of archive mailboxes in this database, run the command Get-Mailbox -Database <Database ID> -Archive. To get a list of all arbitration mailboxes in this database, run the command Get-Mailbox -Database <Database ID> -Arbitration. To disable a non-arbitration mailbox so that you can delete the mailbox database, run the command Disable-Mailbox <Mailbox ID>. To disable an archive mailbox so you can delete the mailbox database, run the command Disable-Mailbox <Mailbox ID> -Archive. Arbitration mailboxes should be moved to another server; to do this, run the command New-MoveRequest <parameters>. If this is the last server in the organization, run the command Disable-Mailbox <Mailbox ID> -Arbitration -DisableLastArbitrationMailboxAllowed to disable the arbitration mailbox. Mailbox plans should be moved to another server; to do this, run the command Set-MailboxPlan <MailboxPlan ID> -Database <Database ID>.
Click here for help... http://go.microsoft.com/fwlink/?linkid=30939&l=en&v=ExBPA.14&id=4a96fd69-9cec-4a48-9571-5c9e8ab3cfe9

Error:
Uninstall cannot continue. Database 'COMPANY Public Folders': The public folder database "COMPANY Public Folders" contains folder replicas. Before deleting the public folder database, remove the folders or move the replicas to another public folder database. For detailed instructions about how to remove a public folder database, seehttp://go.microsoft.com/fwlink/?linkid=81409&clcid=0x409.
Click here for help... http://go.microsoft.com/fwlink/?linkid=30939&l=en&v=ExBPA.14&id=b6e3b32a-8848-46cb-9567-72288ac15f60

Elapsed Time: 00:00:10


Client Access Role Prerequisites
Completed

Elapsed Time: 00:00:07


Hub Transport Role Prerequisites
Completed

Elapsed Time: 00:00:06


Organization Prerequisites
Completed

Elapsed Time: 00:00:02

Any help would be greatly appreciated!

EWS Managed Api 2.2 equivalent code for searching calendar item via ical uid

$
0
0

We need to query exchange for calendar items through their uid. I found a post related to this question. And that linked me to the following blog post:

http://www.infinitec.de/post/2009/04/13/Searching-a-meeting-with-a-specific-UID-using-Exchange-Web-Services-2007.aspx

However, stuff written there was written for an older version of the ews api (or some obsolete library(?)). I am trying to understand how to do the same thing using the latest ews managed api (v 2.2).

Can anyone guide me?


I am a bundle of mistakes intertwined together with good intentions

Viewing all 7132 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>